CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate:
word /text processing in perl

 



newboss
New User

May 8, 2009, 8:11 PM

Post #1 of 2 (387 views)
word /text processing in perl Can't Post

CAn any one advise some logic for text processing
i have given small lines from file for explanation . ..



i have a text file having following types of lines
i have two variables in file c and x
c have fix range say 1 to 9
and each c there is an x associated and representation of text (in file ) is as follows.
file starts ---------------------


c = 1 + 3 + 5 < 9 ---- line 1
x = 25 ---- line 2
2 + 4 ---- line 3
x = 30 ---- line 4

-----------------------------
here + means next value of c ( i.e, 1 + 3 means 1 , 3)
and < means range of c ( i.e. 5 < 9 means 5,6,7,8,9)

in above example i have to extract variable c and x . interpretation is as follows
c =1 x = 25
c =2 x = 30
c =3 x = 25
c =4 x = 30
c =5 x = 25
c =6 x = 25
c =7 x = 25
c =8 x = 25
c =9 x = 25


KevinR
Veteran


May 8, 2009, 9:52 PM

Post #2 of 2 (385 views)
Re: [newboss] word /text processing in perl [In reply to] Can't Post

please do not cross post the same question, that turns people off from wanting to help you.
-------------------------------------------------

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives