|
Post by loyalgurl on Nov 24, 2005 6:06:30 GMT 5.5
hi all
I am new to UNIX shell scritping. I have a file in which i stored numbers( floating point numbers). I need to add them. OK I can use the cut command to get them separated at decimal point. But in this method I will need to store the results in two different files :
cut numfile --fields=1 -d. > tempfile1 cut numfile --fields=2 -d. > tempfile2
I need to know how do I add the contents of a file into a single variable. How is the value assigned to it? I mean I am not able to figure out what loop can be used. Also another question is can this be done without storing the result in 2 temporary files?
Thanks a lot for the help.
It might sound trivial to shell programmers, but please try to help me thanks a lot
|
|
|
Post by loyalgurl on Nov 25, 2005 4:12:32 GMT 5.5
hi all well i got out of this dilemma.....i figured it out thanks a lot hav a gud day take care
|
|