P
psy
Hallo people,
I cant get something done since a while. Its very basic stuff..
I have the following hash for example :
hash = { $-a => "info", $F => "another info"}
and so on, you get the meaning..
Now i use Hash#each_pair so i get the value of the variables and the
info, but I would like also to get a simple string, containing
the name of the variable, so it should look like this :
$-a
info
false
$F
another info
nil
But I cant get it done. Its probably very stupid question, but doesnt
matter what I try - i dont get the name of the key, i always get the
key itself returned... Can somebody help me?
Thanks in advance.
Katja
I cant get something done since a while. Its very basic stuff..
I have the following hash for example :
hash = { $-a => "info", $F => "another info"}
and so on, you get the meaning..
Now i use Hash#each_pair so i get the value of the variables and the
info, but I would like also to get a simple string, containing
the name of the variable, so it should look like this :
$-a
info
false
$F
another info
nil
But I cant get it done. Its probably very stupid question, but doesnt
matter what I try - i dont get the name of the key, i always get the
key itself returned... Can somebody help me?
Thanks in advance.
Katja