You are given two arrays to find out if they are equal?
One way to solve it is to use a hash table. How can I accomplish this using a hash table?
Use std::array:
std::array
std::array<int, 3> var = {{ 1, 2, 3 }}, bar = {{ 4, 5, 6 }}; baz = {{ 1, 2, 3 }}; std::cout << std::boolalpha << (var == baz) // true << (bar == baz); // false
1.4m articles
1.4m replys
5 comments
57.0k users