Someone recently popped into one of the newsgroups I frequent and asked how to parse an INI file. You might have seen those before, with sections and keyword=value lines, like:
I think they started in the Microsoft world, since no sane UNIX hacker would have come up with something like that. No, we come up with things like .Xdefaults and sendmail.cf and termcap. But the request seemed simple: parse the file and gather the information into a hash for quick access, two levels deep, of course.