Jonathan Musto wrote:
> 
> Hi again all,

Hello,

> Thanks for the help before it worked a treat.  What i'm looking to do now
> with this file:
> 
> ght-Skem
> ght-Skem
> ght-Skem
> hjy-TOB
> hjy-TOB
> hjy-TOB
> etc....etc....
> 
> Aswell as removing the repeated data, i could also do with some type of
> count next to the device that shows how many times it was repeated. Like:
> 
> ght-Skem 3
> hjy-TOB 3
> etc...etc...
> 
> Does anyone know of a way this could be done?

perl -i~ -lne'$u{$_}++}{print"$_ $u{$_}"for keys%u' your_text_file


John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to