10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Good evening, need your help please
Need to delete certain files before octobre 1 2016, so need to know how many files im going to delete, for instance
ls -lrt file_20160*.lis!wc -l
but using grep -c to another file called bplist which contains the list of all files backed up doesn match... (7 Replies)
Discussion started by: alexcol
7 Replies
2. Shell Programming and Scripting
can i get a simple script for , Count same word which has come many times in single lines & pars
Eg file would be ==
"Thanks heman thanks thanks
Thanks heman
thanks man"
So resullt should be
Thanks = 5
heman=2
man = 1
thanks in advance :)
Please use code tags for code and... (1 Reply)
Discussion started by: heman96
1 Replies
3. UNIX for Dummies Questions & Answers
Hi
Please can you help how do I count the number of specific characters or words that appear in a file? (8 Replies)
Discussion started by: fretagi
8 Replies
4. Shell Programming and Scripting
Hello,
I have some files and i want to count how many times a string is appeared in each file.
Lets say :
#cat fileA
stringA
sdh
stringB
stringA
#cat fileB
stringB
stringA
sdb
stringB
stringB
I need the output to be something like: (2 Replies)
Discussion started by: @dagio
2 Replies
5. Shell Programming and Scripting
Input:
some random text SELECT TABLE1 some more random text
some random text SELECT TABLE2 some more random text
some random text SELECT TABLE3 some more random text
some random text SELECT TABLE1 some more random text
Output:
'SELECT TABLE1' 2
'SELECT TABLE2' 1
'SELECT TABLE3' 1
I... (5 Replies)
Discussion started by: chitech
5 Replies
6. UNIX for Dummies Questions & Answers
I'm trying to count the number of times each word in the file exist
for example if the file has:
today I have a lot to write, but I will not go for it. The main thing is that today I am looking for a way to get each word in this file with a word count after it specifying that this word has... (4 Replies)
Discussion started by: shnkool
4 Replies
7. Shell Programming and Scripting
#!/bin/sh
count=0
for i in 2 4 6
do
echo "i is $i"
count='expr $count + 1'
done
echo "The loop was executed $count times"
with these scripts
my output is :
i is 2
i is 4
i is 6
The loop was executed expr $count + 1 times
What should I do to get the value instead of 'expr... (17 Replies)
Discussion started by: ymwong
17 Replies
8. UNIX for Dummies Questions & Answers
Hello all,
I always found help for my problems using the search option, but this time my request is too specific. I have two files that I want to compare. File1 is the index and File2 contains the data:
File1:
chr1 protein_coding exon 500 600 . + . gene_id "20532";... (0 Replies)
Discussion started by: DerSeb
0 Replies
9. Shell Programming and Scripting
hello everyone,
I'm trying to learn some scripts but i cant get my head around two of them.
1. how can i write a script that will count the number of times a particular word is used in file?
2. how can i make a script that will take me to a web page from unix?
if anyone could help it... (3 Replies)
Discussion started by: BigTool4u2
3 Replies
10. Shell Programming and Scripting
I have a file. I want to count the time for one string appears in this file
Example:
56
73
34
79
90
56
34
Expected results
2:56
1:73
2:34 (1 Reply)
Discussion started by: anhtt
1 Replies