I'd use sed, but there is a sed equivalent PERL substitute to change such a line. Do you know how to read a file line by line and write the lines to a second file?
Hi All,
I new to perl scripting, trying to write a program to get multiple inputs from the users and it should be stored in one variable. can some one help me with it .
here is the sample code i tried , but its not working.
# cat array.pl
#!/usr/bin/perl
print "enter the total no of... (4 Replies)
The input file contains 4 bytes per row
1 2 3 4
5 6 7 8
9 10 11 12
* * * 108
1 2 3 4
5 6 7 8
9 10 11 12
* * * 108
I need to put them in a horizontal manner and this need to repeat after every 108 lines lso the output comes as
1 2 3 4 5 6 7 8 9 10 11 12 ..... 108
1 2... (4 Replies)
Hi,
plz see the below code , i have catch the file "Orders.20110714.out "file
as a Orders*.out. but it giving me an error .it does not open the file.
if the same thing i have done by code
code-> ls Orders*.out then it gives me the output
Orders.20110714.out
i am trying apply the... (1 Reply)
Is there a way to see or print a sub code?
Sometime a sub could be already defined, but in the debug mode (so, interactively) it could be already out of screen.
So, I would think about a way to check if the sub is defined (just 'defined' is not a problem) and how it is defined.
Also, if... (4 Replies)
Hello All,
I have 2 questions,
1) I am on Unix Sun Solaris korn shell, in my shell scripts i am using
#!/bin/sh Instead of #!/bin/ksh, though it is still working is this correct way of doing and also I am saving the shell script file as abc.sh instead of abc.ksh, please let me know the best... (1 Reply)
hi everybody .
i'm trying to extract a bunch of urls from an http request but when i do that i get nothing .
here it's my code
use LWP::UserAgent;
$url = "$ARGV"; $ua = LWP::UserAgent->new;
$req = HTTP::Request->new(GET=>$url);
$res = $ua->request($req);
if... (0 Replies)