Sponsored Content
Full Discussion: Unable to Print Count
Top Forums Shell Programming and Scripting Unable to Print Count Post 302592174 by balajesuri on Monday 23rd of January 2012 05:12:55 AM
Old 01-23-2012
Wouldn't this suffice?
Code:
FINAL_COUNT=`printf "%012d" $(cat $filesrc $filetgt | wc -l)`

 

10 More Discussions You Might Find Interesting

1. SCO

Non-Root Users Unable to Print

UnixWare 7, Release 7.1.3 We have a customer that has frequent issues with Non-Root users being unable to print. They are able to print w/o issues, but all of the sudden it stops working. The only workaround we have at this point is to reboot the server. It is happening weekly according to... (1 Reply)
Discussion started by: cfshd
1 Replies

2. AIX

Unable to print Cyrillic fonts

Hi All I confifured HP 4250 printer on AIX server..I am unable to print cyrillic fonts prints. Please assist.. (0 Replies)
Discussion started by: kandatihari
0 Replies

3. Shell Programming and Scripting

count identical strings print last row and count

I have a sorted file like: Apple 3 Apple 5 Apple 8 Banana 2 Banana 3 Grape 31 Orange 7 Orange 13 I'd like to search $1 and if $1 is not the same as $1 in the previous row print that row and print the number of times $1 was found. so the output would look like: Apple 8 3 Banana... (2 Replies)
Discussion started by: dcfargo
2 Replies

4. Shell Programming and Scripting

Count and print all repeating words in a line

Gurus, I have a file containing lines like this : Now, number of words in each line varies. My need is, if a word repeats in a line get it printed. Also total number of repeats. So, the output would be : Any help would be highly appreciated. Thanks & Regards (5 Replies)
Discussion started by: AshwaniSharma09
5 Replies

5. Shell Programming and Scripting

Search, group , print count

hi All, need help. have a file like below A, error in 123 B, log files are present A, error in 23444 B, log files are present A, move to next line C, matching messages -- expected output-- A , count =2 , error in * A , count =1 , move to next line B , count =2 , log files are present... (2 Replies)
Discussion started by: arun1401
2 Replies

6. Shell Programming and Scripting

Unable to print dynamic arguments in for loop

Hi All, I want to pass few dynamic arguments to shell script. The number of arguments differ each time I call the script. I want to print the arguments using the for loop as below. But not working out. for (( i=1; i<=$#; i++ )) do echo $"($i)" done /bin/sh test.sh arg1 arg2 arg3 ... (1 Reply)
Discussion started by: laalesh
1 Replies

7. Shell Programming and Scripting

Count Column and Print at last

HI Guys, Count base on column A Input:- U00393 6 000100000 U00393 7 000100001 U00393 8 000100002 U00393 9 000100003 U00393 10 000100004 U00393 11 000100005 U00928 6 000100000 U00928 7 000100001 U00964 6 000100000 U00964 7 000100001 U00964 8 000100002 U00972 6 000100000 U00972... (3 Replies)
Discussion started by: asavaliya
3 Replies

8. Shell Programming and Scripting

Count and print the number of occurences

I have some files as shown below GLL ALM 654-656 654 656 SEM LYG 655-657 655 657 SEM LYG 655-657 655 657 ALM LEG 656-658 656 658 ALM LEG 656-658 656 658 ALM LEG 656-658 656 658 LEG LEG 658-660 658 660 LEG LEG 658-660 658 660 The value of GLL is... (5 Replies)
Discussion started by: arch
5 Replies

9. Shell Programming and Scripting

Unable to print block of data

Hi All, Iam unable to print the below block and getting the error.Can anyone please help me in this. Input Data eaits001z$ echo "-------LINENO_JOBID_VAL--------${LINENO_JOBID_VAL}---" -------LINENO_JOBID_VAL--------58167|253473 58169|253473 58171|253473 58179|253473 58180|253473 58181|257311... (9 Replies)
Discussion started by: cskumar
9 Replies

10. Shell Programming and Scripting

Print count of unique values

Hello experts, I am converting a number into its binary output as : read n echo "obase=2;$n" | bc I wish to count the maximum continuous occurrences of the digit 1. Example : 1. The binary equivalent of 5 = 101. Hence the output must be 1. 2. The binary... (3 Replies)
Discussion started by: H squared
3 Replies
GC(1)                                                         General Commands Manual                                                        GC(1)

NAME
gc - count graph components SYNOPSIS
gc [ -necCaDUrs? ] [ files ] DESCRIPTION
gc is a graph analogue to wc in that it prints to standard output the number of nodes, edges, connected components or clusters contained in the input files. It also prints a total count for all graphs if more than one graph is given. OPTIONS
The following options are supported: -n Count nodes. -e Count edges. -c Count connected components. -C Count clusters. By definition, a cluster is a graph or subgraph whose name begins with "cluster". -a Count all. Equivalent to -encC -r Recursively analyze subgraphs. -s Print no output. Only exit value is important. -D Only analyze directed graphs. -U Only analyze undirected graphs. -? Print usage information. By default, gc returns the number of nodes and edges. OPERANDS
The following operand is supported: files Names of files containing 1 or more graphs in dot format. If no files operand is specified, the standard input will be used. EXIT STATUS
The following exit values are returned: 0 Successful completion. 1 The -U or -E option was used, and a graph of the wrong type was encountered. AUTHOR
Emden R. Gansner <erg@research.att.com> SEE ALSO
wc(1), acyclic(1), gvpr(1), gvcolor(1), ccomps(1), sccmap(1), tred(1), libgraph(3) 21 March 2001 GC(1)
All times are GMT -4. The time now is 03:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy