Reading selected data from text files

..:: sjf ::.. sjf at autograf.pl
Mon Mar 1 03:29:20 EST 2004


Użytkownik "Piet van Oostrum" <piet at cs.uu.nl> napisał w wiadomości
news:wzk728inbx.fsf at Ordesa.local...
> >>>>> "..:: sjf ::.." <sjf at autograf.pl> (SJF) wrote:
>
> SJF> Hello Pythoners!
> SJF> There are a lot of files containing data such as:
>
> SJF> file1:
> SJF> 0950 1550
>
> SJF> file22:
> SJF> 0952 1552
>
> SJF> file3:
> SJF> 1000 1020 1050 1130 1150 1200 1245 1600
>
> SJF> file4:
> SJF> 1002 1022 1052 1132 1152 1202 1247 1602
>
> SJF> file5:
> SJF> 1005 1025 1055 1135 1155 1205 1250 1605
>
> SJF> I want to read from them only that data which produce a following
> sequence SJF> of data:
> SJF> => 0950 0952 1000 1002 1005
> SJF> => 1555 1557 1600 1602 1605
>
> How do you get at these values, as 1555 and 1557 aren't in your input
> files?

ups...
of course it should be:
=> 0950 0952 1000 1002 1005
=> 1550 1552 1600 1602 1605


--
..:: sjf ::..
"Linux is like Wigwam. No gates, no windows... Apache inside ;-)"




More information about the Python-list mailing list