in reply to Re: Comments in my code
in thread Comments in my code
#!/usr/bin/perl -w ##################################################### # Script: mp3_average_year # Author: Jeff Anderson # Date: 03/15/2001 # Comments: finds average year of my mp3 collection ##################################################### use strict; use File::Find; use MP3::Info; my ($sum,$count); my $start = shift || '/mnt/lump/mp3'; find sub { if (/mp3$/) { my $tag = get_mp3tag($_); my $year = $tag->{'YEAR'}; next unless $year =~ /^\d+$/; next unless ($year > 1950 and $year < 2002); $sum += $year; $count++; } }, $start; print "$sum / $count = " . $sum / $count . "\n"; |
UPDATE:
Oh yeah, _PLEASE_ don't actually do what i just did and
actually post gvim rendered HTML, as the resulting HTML
increases in size tenfold. Guess that makes me a
hypnotist.
jeffa
i liked it better than cats, i will use gvim again and again ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re:x3 Comments in my code (gvim syntax highlighting example)
by grinder (Bishop) on Nov 13, 2001 at 14:26 UTC | |
by jeffa (Bishop) on Nov 24, 2001 at 22:25 UTC | |
by grinder (Bishop) on Nov 24, 2001 at 23:40 UTC | |
|
Re: (jeffa) 2Re: gvim syntax highlighting example)
by stefp (Vicar) on Nov 25, 2001 at 21:27 UTC |