In kind of an atempt to get me to program something worth something, I came upon the idea of making an address book. (hey, maybe someday a "little black book!" ha!) Although as of now, I haven't nailed down the interface side, I have some ideas:

That can all be handled later. My question deals with the data part of the program. I'm pretty sure that I want to put the data in a text file (I don't know THAT many women!), read the text file, and store it in the program as a hash of a hash using peoples nicknames (helps to keep it unique) as the keys . i.e.:

%addys = (
     reallyhotchick => {
                 phone=>'555.555.5555', 
                 name=>'Jane Shmoe', 
                 cell=>'555.555.5555', 
                 nick=>'reallyhotchick'}...)

What would be the best way to go about this? (field delimitation, how to get the data into the variables, etc) Is this a stupid way to go about this? I've tried a few things, but I always screw them up somehow. This is really a learning project for me. I will of course post the code upon finishing, but I don't expect to be life changing. If you think there's a better way (leaving out DB's to keep it simple) I open to suggestions. Thanks for your time.


In reply to writing an address book program by mexnix

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.