You need to use curlies for that. The type you are using is called a hash. Perl arrays use square braces, but require integers to index them, just as C does. $index_hash{"hola"}="mundo"; $index_hash{"hello"} = "world"; There is no corresponding type in C, though C++ std::map is close.
Please take a few minutes to look at the Perl Monks Site FAQ, you'll find out how to format your questions more effectively. Code tags are good to know about.
After Compline,
Zaxo
In reply to Re: INDEXED ARRAYS ON C?
by Zaxo
in thread INDEXED ARRAYS ON C?
by entropia
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |