perl 2017-07-28



use warnings;
use strict;
my %hash;
my $source_file=$ARGV[0]; #输入文件
my $dest_file = $ARGV[1];#输出文件
open (FILE,"<$source_file") or die "Cannot open file $!\n"; #打开文件
open (SORTED,">$dest_file") or die "Cannot open file $!\n";
while(defined (my $line = <FILE>))
     #$line=~ s/[\r\n]+//mg;#取出换行符
        $hash{$line} += 1;
foreach my $k (keys %hash) {
        print SORTED "$k\n";#改行打印出列和该列出现的次数到目标文件
close (FILE);
close (SORTED);

将这个#号中的内容添加好以后使用chmod +x 文件名加上权限,使用“./ 源文件 目标文件”命令运行即可

本文由 admin 创作,采用 知识共享署名 3.0,可自由转载、引用,但需署名作者且注明文章出处。

2518 条评论

  1. bzcigftr

    perl脚本去除文件中重复数据 - 青花瓷

    1. Off White Jordan 1
      Off White Jordan 1

      Jordan 12 Gym Red
      Nike Outlet satore
      Nike Outlet satore
      Nike Outlet satore
      retro jordan 33
      cheap jerseys
      custom nfl jerseys
      jordan 11 concord 2018
      Jordan 12 Gym Red
      Red Jordan 12
      Yeezy Shoes

    2. Williamimife

      best buy for cialis
      cialis espn.
      generic cialis online pharmacy review
      why is cialis so expensive
      Cheap cialis buy online
      comprare cialis online sicuro
      cialis online bestellen nachnahme
      cialis 5mg price canada
      peux t on acheter du cialis en espagne

    3. WilliamDor

      when is cialis going off patent
      get cialis online
      adcirca vs cialis price
      delta enterprises cialis
      popular pills online comprar cialis spain
      cialis for sale net
      cialis kupovina
      fast shipping cialis
      Cialis 100 mg

    4. Williamimife

      good place to buy generic cialis
      cialis drug class
      cost comparison for cialis
      cumpar cialis online
      Cheap cialis buy online
      vente cialise
      acquistare cialis online con postepay
      buy cialis in soho
      bph and cialis
      Cialis 100 mg cheap price

    5. Gerardben
      Gerardben cialis without prescription cialis without prescription

    6. ArnoldInfus

      buy generic cialis tadalafil
      cost for cialis
      Buy Cheap Cialis
      cialis sklep online
      cialis while trying to get pregnant
      Buy Cheap Cialis Online
      cialis spedizione gratuita
      cialis sample packs
      Buy Cheap Cialis Online

    7. DavidMof

      socialist caucus
      cialis australia next day delivery
      generic cialis at walmart
      best place to buy cialis jelly
      5 mg cialis coupon printable
      cialis efectos
      liquid cialis blue bottle

    8. ArnoldInfus

      cialis purchace on line fast no rx
      ordering cialis from canada
      buy cialis
      cialis preise rezeptfrei
      everyday cialis online
      Buy Cialis Online
      cialis price in rupees
      genuine cialis cost
      Buy Cheap Cialis Online

    9. DavidMof

      cialis online italia
      drug supplier cialis generic
      interactions for cialis
      cialis online nederland
      costco price for cialis
      cialis manufacturer coupon
      best price online cialis 10mg
      cialis store erfahrungen

    10. ArnoldInfus

      cheap cialis from mexico
      cialis madrid
      Cheap Cialis
      best website for generic cialis
      online pharmacy for cialis
      Buy Cheap Cialis Online
      cialis prescription cost
      long term use cialis effects
      Buy Cheap Cialis

    11. Gerardben

      buy cialis without prescription
      cialis without prescription online buy cialis without prescription cialis without prescription online

    12. DavidMof

      does insurance cover cialis
      gunstiges cialis
      Buy Cheap Cialis
      cialis 20mg preisvergleich
      lady cialis side effects
      Buy Cheap Cialis Online
      cialis super active vs cialis
      vancouver cialis

    13. DavidMof

      order female cialis free trial
      comprar cialis en farmacia online
      do you need a prescription for generic cialis
      cialis 5mg best price canada
      what is cialis
      cialis 25mg
      best cialis

    14. Gerardben
      cialis without prescription online buy cialis without a doctor's prescription cialis without a doctor's prescription

    15. DavidMof

      cialis 10mg prix
      generic cialis fedex
      Buy Cheap Cialis
      www buycialisonlinecheap
      necesito comprar cialis
      cialis 30 day sample
      cialis effet secondaire
      cialis liquid

    16. ArnoldInfus

      100 mg generic cialis
      cialis super active canada
      Buy Cheap Cialis Online
      non de site pour cialis
      acquistare cialis generico con ebay
      Buy Cheap Cialis
      fake cialis
      brand cialis online usa
      Cheap Cialis

    17. DavidMof

      cialis tadalafil kaufen
      cheaper than cialis
      cialis at tesco pharmacy
      super facialist vitamin c serum review
      Cialis Cheap Buy Online
      much does cialis cost cvs
      generic cialis online overnight

    18. Duanedyday

      sample pack of cialis online
      da narucim cialis
      Cheap cialis buy online
      cialis 20g
      monthly cost of daily cialis
      cheap cialis extra strength
      cialis to buy in south africa
      20 mg cialis
      discount cialis canada
      buy cialis with money order

    19. DavidMof

      was kostet cialis in der apothekecialis pills shanghai cialis cheap
      cialis reimportcialis dosage options Buy cheap cialis

    20. DavidMof

      Cialis Super Active usafree cialis coupons cialis cheap
      cialis online sicuro opinionidove comprare cialis generico online forum Buy cheap cialis

    21. DavidMof

      sito sicuro comprare cialiscialis tadalafil 20mg reviews cheap cialis
      rising cost of cialispastillas cialis de canada Buy cheap cialis

    22. Duanedyday

      one week supply of cialis
      buy cialis in portugal
      20 mg cialis
      cialis sold on the street
      national socialist movement
      cialis money order
      cialis red pill
      cialis buy online
      pharmacy discount card for cialis
      what is the price of cialis at walmart

    23. Williamimife

      cialis in delhi
      is online cialis legitimate
      buy cialis generic canada
      best price cialis 20mg
      buy cialis
      cialis without insurance
      cialis strength
      cialis instructions
      buy generic cialis from canada
      20 mg cialis buy

    24. DavidMof

      cialis miglior prezzosuper active cialis cialis cheap
      what does cialis for daily use cost 105buy orginal cialis cheap cialis

    25. DavidMof

      cialis price amazoncialis pro fastest delivery cheap cialis
      pildora cialisextra meds buy cialis Buy cheap cialis

    26. Duanedyday

      rite aid pharmacy cialis cost
      actors in cialis commercials
      20 mg cialis buy
      seguros los genericos de cialis
      cialis cost without insurance
      blue cross blue shield cialis cost
      best online pharmacy for generic cialis
      Cheap cialis buy
      cialis acquistp
      harm of cialis two pills in 24 hours

    27. DavidMof

      cialis cheapest price canadacialis for daily use cost at walmart cheap cialis
      buy cialis portland oregoncialis and alcohol cheap cialis

    28. Williamimife

      apotheke cialis
      cialis afhalen
      cialis dosages available
      100 mg cialis
      cheapest cialis 20mg
      order cialis over night
      brand name cialis discount online no rx
      a secure site to buy cialis on ebay
      buy cialis

    29. Gerardben

      trusted tabled cialis softabs
      medicine cialis tablets
      buy cialis without prescription
      generic cialis free sample
      cialis or vardenafil 20mg tablet
      cialis without prescription
      cialis without prescription forum
      cialis singapore pharmacy
      cialis without a doctor's prescription
      buy cialis auckland
      best buy cialis
      cialis without a doctor's prescription

    30. Gerardben

      best website to buy cialis
      discount cialis with prescription
      cialis without a doctor's prescription
      cialisonline4all online pharmacy review
      cialis chewable reviews
      buy cialis without a doctor's prescription
      cialis online overnight shipping
      cialis dosage instructions
      cialis without prescription
      cialis generika ohne kreditkarte
      buy cialis in arizona

    31. Gerardben

      order cheap cialis
      super cialis 100mg
      cialis without a doctor's prescription
      cialis generika online kaufen osterreich
      cialis cost chemist warehouse
      buy cialis without a doctor's prescription
      cialis oder kamagra
      cheap cialis super
      cialis without prescription
      cialis pricing walgreens
      cialis pill brand 5mg
      buy cialis without prescription

    32. RalphSpamb

      buy real viagraviagra patent expiration date Viagra 100 Mg
      viagra generic online canadaviagra contrareembolsoViagra 100Mg

    33. AnthonyElals

      forum_site_achat_cialiswas ist cialis
      rite aid pharmacy cialis costcialis international shipping
      comprar cialis online en mexicocialis daily vs 36 hour
      cialis kaufen ohne kreditkartewhy would cialis stop working
      cialis rush ordercialis price checker
      generic cialis canada customswhat is cialis 20mg used for

    34. RalphSpamb

      viagra zonder voorschriftgeneric viagra without rx buy viagra 100mg
      which is better viagra or levitraerfahrungsbericht viagrageneric viagra 100 mg

    35. AnthonyElals

      what is the cost of cialis 5mgwalgreens pharmacy prices cialis
      cialis patenttigeneric cialis 10mg reviews
      cialis online schweizcheapest way to buy cialis
      buy cialis manchestercialis drugs online
      cialis for sale dublincialis generic best price and delivery
      cialis naturalbuy cialis online france п»ї

    36. HermanEdunc

      cialis online without subscribtiondoes cialis make you horny
      buy cialis cypruscialis 30 tadalafil 30mg ml
      cheapest cialis genericcialis 100 mg prezzo
      cialis100mgorder cialis without prescription
      buy cialis online using echeckachat cialis 5mg
      cialis black 800 mg reviewslloyds pharmacy cialis 10mg

    37. AnthonyElals

      cialis internet purchasesecure sites to buy cialis
      insurance cialis daily bhpvente cialis france
      jual cialis onlinecialis generic name
      cialis in sam cluborder real cialis
      cialis rezeptfrei aus deutschlandcialis same day shipping
      cialis discount couponcialis toronto п»ї

    38. RalphSpamb

      sustitutos viagranombres de viagras Viagra 100Mg
      viagra calgaryviagra street priceViagra 100Mg

    39. AnthonyElals

      sams club pharmacy cialiscialis private prescription charges
      cialis controindicazionicialis five day delivery usps
      buy generic cialis europe40mg dose of cialis
      cost of cialis in uaecialis 4cpr riv 10 mg costo
      cialis online in 3 dayscialis otc
      cialis picturecialis tablete cena

    40. AnthonyElals

      what dosage of cialis should i takecheap cialis extra strength
      buy cialis online no prescription canadacostco pharmacy cialis cost
      cialis to buy mail orderbuy cheap cialis site
      buy generic cialis online europecialis pills sale ontario
      veilig online cialis kopencialis cheapest price canada
      recensioni acquisto cialis onlinecialis super aktiv

    41. Gerardben

      comprime cialis cialis without doctor's prescription

    42. Henryfrino

      5mg daliy cialis reviews cialis 40mg

    43. Henryfrino

      cheap cialis super active ride cialis 60mg

    44. Henryfrino

      cialis in frankreich

    45. Henryfrino

      cialis online kaufen deutschland cialis 20mg

    46. TerenceGlulp

      discount vouchers for cialis buy cialis

    47. Henryfrino

      search cialis

    48. TerenceGlulp

      cheapest cialis usa Cheap cialis buy online

    49. Henryfrino

      cialis no presciptiononline cialis 20mg

    50. TerenceGlulp

      does cialis daily work cialis cheap

    51. Henryfrino

      does cialis lower blood pressure

    52. Henryfrino

      cialis with depoxetine Buy cialis 20mg

    53. TerenceGlulp

      cialis insurance online cheap

    54. TerenceGlulp

      fastest super cialis delivery cialis cheap

    55. Henryfrino

      order cialis online with paypal Buy cialis 60 mg

    56. Gerardben

      much does cialis cost cvs

      cialis coupon voucher cialis without a doctor's prescription

    57. BrianEcope

      free dating sites toronto ontario blind dating watch online dating cocoa beach fl
      adult dating mia gurnee il how to check dating sites using email address online dating in orlando fl
      adult dating site with free messaging Cougar Com Dating online dating sites without credit card payments
      how many people act differently in person after online dating male ironton ohio 45 dating dating services san diego ca
      san diego best online dating sites asian singles dating chicago is spark adult hookup dating app reviews
      what indicates quality with free dating sites native american dating sites why do w