12-20-2011
Sounds nice, but if more than one file is different it would end at the first one and not find the others, correct? I will remember the -q parameter for later. But I don't think it's what I can use here. Thanks though.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
:confused:
Is it possible to delete array elements dynamically.For instance,consider an array( a b c d ) ,now can i delete array (the third element 'c').So that the array becomes array(a b d)..
Thanks in advance!! (1 Reply)
Discussion started by: tj23
1 Replies
2. Shell Programming and Scripting
hi guys,
i have the following script and when i run it i get blank lines on the screen.. i am trying to display the contents of array var..
#!/usr/bin/bash
var=`awk 'NR>20&&NR<31' try.sum | awk '{print $4}'`
echo "${var}" (1 Reply)
Discussion started by: npatwardhan
1 Replies
3. Shell Programming and Scripting
hi guys,
i have an array called ARRAY which has elements in it... i am trying to assign elements of ARRAY to master_array..
i get a =: command not found error..
i=0
while
do
${master_array}=${ARRAY}
((i++))
done
is there something i am missing? (4 Replies)
Discussion started by: npatwardhan
4 Replies
4. Shell Programming and Scripting
Hi,
I have 2 arrays.
I have to compute symmetric difference!
@arr=qw(19205134 18630215 18453487 18416242 18338715 18227590 17698645);
@arr1=qw(18227590 18053561 17698645 16966777);
#The code which i used is this!
@union = @isect = @diff = ();
%union = %isect = ();
%count =... (3 Replies)
Discussion started by: vanitham
3 Replies
5. Shell Programming and Scripting
Hi,
Could someone please help me with this? I have two arrays and I need to generate third array containing difference between the two. For example -
@Array1 = ;
@Array2 = ;
I would like to find difference between these two and generate third array that contains the difference. In... (5 Replies)
Discussion started by: sncoupons
5 Replies
6. Shell Programming and Scripting
Hi,
I need an elegant solotion in php. I need to compare 2 arrays (array1 & array2), to find all instances of array 2 which is not in array1.
I don't want to see any instances of array1 wich is not in array2 (here "the")
Array1: This, is, the, data, of, array1
Array2: this, is, data, Of,... (2 Replies)
Discussion started by: lowmaster
2 Replies
7. Shell Programming and Scripting
Hi,
I have 2 arrays:
@a=qw(19190289 18381856 12780546 10626296 9337410 8850557 7740161 8101063);
@b=qw(18309897 17612870 10626296 16871843 7740161 19947571 18062861);
$len=@a;
print "<br> length of array1: $len<br>";
$len1=@b;
print "<br> length of array2: $len1<br>";
The output... (3 Replies)
Discussion started by: vanitham
3 Replies
8. Shell Programming and Scripting
Hi All,
Got this 2 file namely a.txt and b.txt, i want to know how to extract the difference between the two files, the output will be written to a file.
e.g.
>>a.txt<<
Nokia 1100
Nokia 1200
Nokia 1300
Nokia 1400
Nokia 1500
Nokia 1600
Nokia 1700
Nokia 1701
Nokia 1702
Sagem 1100... (3 Replies)
Discussion started by: shtobias
3 Replies
9. Shell Programming and Scripting
trying to sum elements in an array using bc and getopt,i have a file with names and thier vaules if the names appears 3 times i should multiply its value with 3 then find the sum of all the elements together
cat foo.txt
max 2.3
henry 3
fransis 4.5
max 2.3
henry 3
max 2.3
it should... (1 Reply)
Discussion started by: elginmulizwa
1 Replies
10. Shell Programming and Scripting
I have the following code and for some reason when I call the program using
/home/tcdata/tatsh/trunk/hstmy/bin/bash/raytrac.bash --cmod=jcdint.cmod
I get
hasArgument =
hasArgument = true
Somehow the array element is returning even though I have not chosen the option.
... (41 Replies)
Discussion started by: kristinu
41 Replies