[shell]$ time icpc -o string_in_array string_in_array.cppHowever, with gcc it's fine:
Fatal compilation error: Out of memory asking for 36872.
compilation aborted for string_in_array.cpp (code 1)
[cpp]$ time g++ -o string_in_array string_in_array.cpp real 0m14.287s user 0m12.877s sys 0m0.800s [/cpp]If I compile with no optimization it's a little better:
[cpp]$ time icpc -o string_in_array string_in_array.cpp -O0 real 3m20.380s user 3m17.324s sys 0m1.276s [/cpp]However, it uses 350MB of RAM and 100% cpu for 3m 20s. That's 14x slower than gcc.