Re: hashes and string
$_ = 0000; @h{0..23} = /./g; (no '00' keys) -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: hashes and string
$_ = 0000; @h{grep~s/^.$/0$/,0..23} = /./g; I hope that works -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to delete space at end of line
@==map$`x/ ?$/, maintainable? sure ;-) -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Match pattern and print next line
an alternative: $print, /- Student Id|$/ for LOG; -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Array problem, I think
0 @F1@ FAM 1 HUSB @I13@ 1 WIFE @I14@ 1 CHIL @I8@ 0 @F2@ FAM 1 HUSB @I10@ 1 WIFE @I8@ 1 CHIL @I11@ 1 CHIL @I12@ etc. $/ = undef; for (split /\n0/, ) { ($key) = /\@(..)/; $hash{$key} = [ /\@(\w+)\@$/gm ]; } $individuals{F1}[0] = I13; $individuals{F1}[1] = I14; $individuals{F1)[2] = I8; $individuals{F2)[0] = I10; $individuals{F2)[1] = I8; $individuals{F2)[2] = I11; $individuals{F2)[3] = I12; untested. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: File search (Help!!!!!)
this is better, i just wanted to be smart :-) #!perl @command = ('echo 1', 'echo 2', 'echo 3'); -f /dir$_/file/search/filename || system($command[$_-1]) for 1..3 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: File search (Help!!!!!)
On Sun, 10 Nov 2002 11:27:17 -0500 SilverFox [EMAIL PROTECTED] wrote: Hi all, I'm looking for the best way to search/test multiple directories for a specific file and exec a command depending on which directory is missing the file. any advice? #!perl @command = ('echo 1', 'echo 2', 'echo 3'); /dir$_/file/search/filename* || system($command[$_-1]) for 1..3 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: sort two patterns, control structure help needed
perl -ne '$;[$_99].=$_}{print@' infile.txt outfile.txt :) if no additional sorting is required -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Help with Hash values and variable interpolation
112.58.26.32.32770 192.35.51.30.53: 64596[|domain] (DF) 112.58.26.32.32770 192.100.59.110.53: 24685 [1au][|domain] (DF) 112.58.26.4.2506 216.148.227.69.80: . ack 3280436924 win 2920 (DF) 112.58.26.4.2506 216.148.227.69.80: . ack 1759 win 1162 (DF) 112.58.26.4.2498 66.207.130.76.80: . ack 2195940947 win 7906 (DF) 112.58.26.4.2498 66.207.130.76.80: R 2576805184:2576805184(0) win 0 (DF) perl -ne '@a[/(\d+):/]++}{print Port 53: $a[53]\t Port 80: $a[80]\n' infile.txt Port 53: 2 Port 80: 4 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]