Bash ~ Perl ~ Python ~ Batch ~ Ruby
Monday, 17 February 2014
Counting no words in a file (Perl)
open("FILE","sam");
while($line=<FILE>)
{
print $se++."\n" while($line=~m/[\s]+/g);
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment