No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
This snippet while(<>) { for my $word ( split(/\s+/) ) { $idx{$word}{$page_number} = 1; } $page_number++ if ( /\014/ ); } is part of a perl script which indexes words by page (I'm trying to rewrite it in python). I do not understand it, or rather, I can guess a … |
|
Hi everybody. Maybe I was able to write a script which takes an input file, strips off part of the anchor tag(<a ....>) and returns a new file. I'd like to know your opinion about the script; it works, but I have the feeling that there is something that can … |
|
Hi everybody. Mi first post: I'm trying to learn some python From CLI I run: python file.py [ICODE]import sys lines = 0 words = 0 chars = 0 for line in sys.stdin: lines = lines +1 words = words +1 chars = chars + 1 print lines, words, chars[/ICODE] I … |