in reply to Re^2: to copy certain content in file & repeat it .
in thread to copy certain content in file & repeat it .
Hi, the code you posted does not compile, part of asking a question effectively, is to make sure your code compiles before posting.
This reads from a file until it reaches the end. Filehandles are iterators. Once you reach the end, the subsequent while(<FH>) loop will not be entered
@arr =$_;
This sets @arr to the value of $_; It doesn't add values to @arr, for that you need the push function
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: to copy certain content in file & repeat it .
by harshmane (Initiate) on Jul 01, 2011 at 09:27 UTC | |
by Anonymous Monk on Jul 01, 2011 at 10:02 UTC | |
by harshmane (Initiate) on Jul 01, 2011 at 10:55 UTC | |
by Anonymous Monk on Jul 01, 2011 at 11:20 UTC |