C++
Which of t ...
Site Language: English
Українська
English
Русский
Programming Tests
Login
Sign Up
Programming Tests
Theory
Snippets
Papers
Landing
Android
Prices
FAQ
Cosmo Story
Terms and Conditions
Privacy Policy
Cookies Policy
Send Feedback
Which of the following containers is have search complexity O(n)?
std::vector
std::list
std::set
std::hash_set
Explanation
std::set
has logarithmic complexity (red-black tree). The complexity of
std::hash_set
depends heavily on the implementation of the hashing function, but it is tried to be selected in such way that the element is accessed with constant complexity.
complexity
containers library
std::string
Like
Login in
to like
Comment
Login in
to comment
Share
Tweet
C
++
Quiz
Login to learn C++
or
Read more about
C++ Quizzes
Follow CodeGalaxy
Mobile Beta
Send Feedback
Sign Up Now
or
Subscribe for future quizzes
Login in to like
Login in to comment