Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Merging of custom array

by jwkrahn (Abbot)
on Jul 19, 2019 at 19:52 UTC ( [id://11103046]=note: print w/replies, xml ) Need Help??


in reply to Merging of custom array

#!/usr/bin/perl use strict; use warnings; @ARGV == 2 or die "USAGE :: perl max_tran_update.pl <<cell_list>> <<PV +T_LIST>> \n\n"; my $cell_list = $ARGV[0]; # input cell_list my $pvt_list = $ARGV[1]; # input pvt_list open CFILE, '<', $cell_list or die "Can not open cell_list because: $! +"; open PFILE, '<', $pvt_list or die "Can not open pvt_list because: $!" +; my @cell_file = map s/\s+\z/_X/r, <CFILE>; while ( <PFILE> ) { chomp; print join( ' ', map s/_\k.+\z/$_/r, @cell_file ), "\n"; }

Replies are listed 'Best First'.
Re^2: Merging of custom array
by anirbanphys (Beadle) on Jul 22, 2019 at 07:29 UTC
    Delight to see your solution jwkrahn...

    Thanks,

    Anirban

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11103046]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (6)
As of 2024-03-29 09:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found