Hello everyone,
What I am trying to do is create a hash to test some code I wrote. The problem is I have little experiance with hashes so I went on line and searched the web and put together my best guess. The Hash call I need to meet is as follows:
@idlarge = ($Data_Hash{$Call_Hash{"TST_" . "IDS_Large_1"}}, $Data_Hash
+{$Call_Hash{"TST_" . "IDS_Large_2"}}, ...
@idsmall = ($Data_Hash{$Call_Hash{"TST_" . "IDS_Small_1"}}, $Data_Hash
+{$Call_Hash{"TST_" . "IDS_Small_2"}}, ...
@Vg = ($Call_Hash{"OPT_" . "VGS_1"}, $Call_Hash{"OPT_" . "VGS_2"}, ...
What I am doing is creating the hash to these calls. After searching online I put it all together and came up with the following:
%Data_Hash = (
%Call_Hash = (
TST_IDS_Large_1 =>2.9E-12,
TST_IDS_Large_2 =>1.85E-12,
TST_IDS_Small_1 =>1.86E-9,
TST_IDS_Small_2 =>2.83E-9,
),
OPT_VGS_1 =>0,
OPT_VGS_2 =>0.02,
);
From trying to call the hash I can tell you that what I have is not correct. I can get the information in the first level of the hash but nothing beneith it. Can someone please tell me where I have gone wrong in creating the hash?
Aaron
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.