Can some body tell me how to print number of line from a particular file, with sed. ?
Input file format
AAAA
BBBB
CCCC
SDFFF
DDDD
DDDD
Command to print line 2 and 3 ?
BBBB
CCCC
And also please tell me how to assign column sum to variable.
I user the following command it... (1 Reply)
Hello,
I think its a sinple query but somehow i m stucked up here...
I am trying to enter n number of inputs from the user and write them in
an input file ie row wise...
I tried standard commands like
$echo "enter the inputs for the file"
$read var1 var2 var3 var4
test1 test2... (14 Replies)
Hi,
I need help in printing out the dates with the largest value in front of it using awk.
436 28/Feb/2008
436 27/Feb/2008
436 20/Feb/2008
422 13/Feb/2008
420 23/Feb/2008
409 21/Feb/2008
402 26/Feb/2008
381 22/Feb/2008
374 24/Feb/2008
360... (7 Replies)
Dear all,
I have to transform a bunch of files into a new format. how to do it with bash script, especially with 'awk' command.
the original data
O,0,0.2839896442,-1.1628392411,-1.5976515479
Cr,0,-0.0502858628,-0.1725974837,-0.380627632
C,0,2.4506658279,-0.476964918,0.2299298249
... (3 Replies)
Ok, so I know there's a way to do this, but I've been trying to find out all afternoon with no luck. I think it should print out something like this:
1 bin
2 daemon
6 duo
Where the numbers on the left are the number of processes being run by the user whose name is listed on the right. Is... (4 Replies)
Is it possible to print max number of 2 columns - awk
note: print max if the integer is positive and print min if the integer is negative
input
a 1 2
b 3 4
c 5 1
d -3 -5
d -5 -3
output
a 2
b 4
c 5
d -5
d -5 (4 Replies)
I would like to print the number of records of 2 files, and divide the two numbers
awk '{print NR}' file1 > output1
awk '{print NR}' file2 > output2
paste output1 output2 > output
awl '{print $1/$2}' output > output_2
is there a faster way? (8 Replies)
Hello experts,
Shown below is the 2 column sample data(there are many data columns in actual input file),
Key, Data
A, 1
A, 2
A, 2
A, 3
A, 1
A, 1
A, 1
I need the below output.
Key, Data
A, 2
A, 2
A, 3
A, 1
A, 1
A, 1 (2 Replies)
Hi
I want to use awk to match where field 3 contains a number within string - then print the line and just the number as a new field.
The source file is pipe delimited and looks something like
1|net|ABC Letr1|1530|||
1|net|EXP_1040 ABC|1121|||
1|net|EXP_TG1224|1122|||
1|net|R_North|1123|||... (5 Replies)
Say I have this line:
read -p "Enter 3 numbers: " num1 num2 num3;
I want to write a while loop that repeatedly asks for input if the number of inputs entered is not equal to 3.
I don't know the correct command to find the number of inputs entered. Help, please? (4 Replies)
Discussion started by: jejemonx
4 Replies
LEARN ABOUT XFREE86
what-patch
WHAT-PATCH(1) General Commands Manual WHAT-PATCH(1)NAME
what-patch - detect which patch system a Debian package uses
SYNOPSIS
what-patch [options]
DESCRIPTION
what-patch examines the debian/rules file to determine which patch system the Debian package is using.
what-patch should be run from the root directory of the Debian source package.
OPTIONS
Listed below are the command line options for what-patch:
-h, --help
Display a help message and exit.
-v Enable verbose mode. This will include the listing of any files modified outside or the debian/ directory and report any additional
details about the patch system if available.
AUTHORS
what-patch was written by Kees Cook <kees@ubuntu.com>, Siegfried-A. Gevatter <rainct@ubuntu.com>, and Daniel Hahler <ubuntu@thequod.de>,
among others. This manual page was written by Jonathan Patrick Davies <jpds@ubuntu.com>.
Both are released under the GNU General Public License, version 3 or later.
SEE ALSO
The Ubuntu MOTU team has some documentation about patch systems at the Ubuntu wiki: https://wiki.ubuntu.com/PackagingGuide/PatchSystems
cdbs-edit-patch(1), dbs-edit-patch(1), dpatch-edit-patch(1)DEBIAN Debian Utilities WHAT-PATCH(1)