haast
asked on
Beginners question
I am a beginner and this probably an extremely simple question, please excuse me.
How do I reverse a flatfiles contents, what I mean by reverse is this:
Existing flatfile contents.
1\n
2\n
3\n
What I want to convert it to is:
3\n
2\n
1\n
This is how I currently read the file:
open(FILE,"$dbase")
@all=<FILE>;
close(FILE);
How do I reverse a flatfiles contents, what I mean by reverse is this:
Existing flatfile contents.
1\n
2\n
3\n
What I want to convert it to is:
3\n
2\n
1\n
This is how I currently read the file:
open(FILE,"$dbase")
@all=<FILE>;
close(FILE);
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you, it works fine.
@reverseAll = reverse @all