|
|
вернуться в форумAC Послано Baz 5 ноя 2011 20:23 #include <cstdio> #include <map> std :: map<int, int> a; int ans = 0, n, c; int main() { while (scanf("%d", &n) == 1) for (; n; n--) scanf("%d", &c), ans += ++a[c] == 3; printf("%d", ans); } Edited by author 05.11.2011 20:31 Re: AC can you explain the function/name "map" ? which language used in code above? Re: AC map is in C++ STL and it is like a binary search tree. |
|
|