cppreference.com > C++ Maps > count
count
Syntax:
  #include <map>
  size_type count( const key_type& key );

The function count() returns the number of occurrences of key in the map.

count() should run in logarithmic time.