How do I use unordered_map?

I have been using maps a lot lately.Recently I tried unordered_map.
I simply took the same syntax. But changed the declaration to ‘unordered_map’ instead of ‘map’.

I shows compilation error. What is the problem?

Here’s a link to the code-


[1]

Also where can I find good tutorials on STLs?


  [1]: http://ideone.com/H12vJv

just change the version to c++14 in ideone. For studying stl link1, link2.

For good editorials on STL refer to http://en.cppreference.com and http://www.cplusplus.com/reference

Also a crash course is available at TopCoder Feature Articles and Topcoder

Basically the topcoder also list one of the best macros used by programmers for stl in generalised way.

Happy Coding :slight_smile:

1 Like

Thanks! It Worked