S
Shashank Khanvilkar
Hi,
Any help is appreciated.
I have data in the following format
A
B=2
C=3
B
S=2
T=10
....
I need to populate a hash data structure (%graph) in perl so that %graph
will have the form
%graph = (
A => {B=>2,C=>3},
B => {S=>2,T=>10}
}
Assume that I have a program that has read A in $A, B in $B and so on
and the integers in $int. Can I Do the following:
%graph{$A}{$B} = $int
to populate the above hash of the hash.
Thanks
Shashank
Any help is appreciated.
I have data in the following format
A
B=2
C=3
B
S=2
T=10
....
I need to populate a hash data structure (%graph) in perl so that %graph
will have the form
%graph = (
A => {B=>2,C=>3},
B => {S=>2,T=>10}
}
Assume that I have a program that has read A in $A, B in $B and so on
and the integers in $int. Can I Do the following:
%graph{$A}{$B} = $int
to populate the above hash of the hash.
Thanks
Shashank