+ 2

std::count() not working!

Why does this function not work in the code playground? It runs my code fine in VS2017, but not on here....

12th Mar 2018, 5:10 AM
William Then
William Then - avatar
4 Answers
+ 6
You need to include <algorithm> for count to work here. IDEs like VS automatically include some headers for you, while Code Playground doesn't.
12th Mar 2018, 5:40 AM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 4
Can you show your code?
12th Mar 2018, 5:36 AM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
12th Mar 2018, 5:38 AM
William Then
William Then - avatar
+ 1
Wow awesome! Thanks!
12th Mar 2018, 5:57 AM
William Then
William Then - avatar