Visit Our UNIX and Linux User Community

Search Results

Search: Posts Made By: dipanchandra
110,589
Posted By complex.invoke
Tetris Game -- The Art Of Shell Programming
GitHub - deepgrace/tetris: Tetris implementation in all kinds of Programming Languages (https://github.com/deepgrace/tetris)

Usage: bash Tetris_Game [ <runlevel> [ <previewlevel> [ <speedlevel> [...
2,771
Posted By neutronscott
Assuming no ':' occurs after the first one ... ...
Assuming no ':' occurs after the first one ...


$ awk -F: '$1=="Sample"{print $1,tolower($2);next}$1=="domain"&&e=index($2,"@"){print $1,substr($2,1,e-1);next}1' OFS=: input
Sample: abcdefgh...
2,771
Posted By joeyg
Confused...
$ cat sample16.txt
Sample: ABCdefgh
domain: when you think abcd@tester.com
domain: abcdefgh@tester2.com
Goods for purchase:234
domain: efgh@anyother.com
Sample: PQRST
Sample: nmjkl
Sample:...
2,318
Posted By ahamed101
An awk solution... awk '{b+=$1}END{print...
An awk solution...


awk '{b+=$1}END{print a-b}' a=8725 input_file


--ahamed
14,325
Posted By Perderabo
Process accounting can do this. It's a chore to...
Process accounting can do this. It's a chore to set up. It also puts quite a load on the system since records must be written to disk for every process. It also consumes a lot of disk space but...
32,465
Posted By danmero
awk '{gsub(/[|]+/,"=")}1' file Please learn to...
awk '{gsub(/[|]+/,"=")}1' file
Please learn to use [code] tags when you post code or sample data.
Thanks.
32,465
Posted By Scrutinizer
awk '$1=$1' FS='[|]*' OFS== file sed...
awk '$1=$1' FS='[|]*' OFS== file
sed 's/||*/=/g' file
tr -s \| = < file
Showing results 1 to 7 of 7

 

Featured Tech Videos

All times are GMT -4. The time now is 03:57 AM.
Unix & Linux Forums Content Copyright 1993-2021. All Rights Reserved.
Privacy Policy