in reply to Re: Ugly variable-length record handling
in thread Ugly variable-length record handling
I'm not sure that using tell and seek leads to a more elegant solution (or at least I'm not sure how to use them to craft a more elegant solution).
I can only detect the start locations when I get to them (and the start-line has to be included in temp.dat).
Just to clarify - here is a simplified (and very short) version of export.dat:
100000001 200546Mary 200549#0002897 20055100001 100000003 200546Kathy 200547#0002530 200549#0002897 200552123 Elm Street
Tom Melly, pm@tomandlu.co.ukmap{$a=1-$_/10;map{$d=$a;$e=$b=$_/20-2;map{($d,$e)=(2*$d*$e+$a,$e**2 -$d**2+$b);$c=$d**2+$e**2>4?$d=8:_}1..50;print$c}0..59;print$/}0..20
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Ugly variable-length record handling
by jettero (Monsignor) on Dec 28, 2006 at 14:33 UTC | |
by Melly (Chaplain) on Dec 28, 2006 at 15:02 UTC |