Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!uunet!munnari.oz.au!frankland-river!pem From: pem@frankland-river.aaii.oz.au (Paul E. Maisano) Newsgroups: comp.lang.perl Subject: reverse of localtime() Message-ID: <1176@frankland-river.aaii.oz.au> Date: 28 Feb 90 00:40:10 GMT Organization: Australian AI Institute Lines: 24 I am writing a perl program at the moment which is doing a lot of manipulation of dates and times. I am maintaining a text file which contains dates such as 24/04/89 and to manipulate these dates easily I would like to convert that to "the number of seconds since Jan 1970". This is the reverse of what localtime() does. [I can't keep the number of seconds in the file rather than the date either since the file may be modified by hand.] My unix manual (on SUN/OS) says there is a timelocal() function. Is this a worthwhile addition to perl ? I can't see a simple way of doing it in perl. I was originally going to write the program in C for speed reasons but I think perl would be fast enough. I don't really want to write it in C but... :-( ------------------ Paul E. Maisano Australian Artificial Intelligence Institute 1 Grattan St. Carlton, Vic. 3053, Australia Ph: +613 663-7922 Fax: +613 663-7937 Email: pem@aaii.oz.au