Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Apr 2006 17:40:49 -0500
From:      "Nikolas Britton" <nikolas.britton@gmail.com>
To:        "FreeBSD Questions" <questions@freebsd.org>
Subject:   Perl: sort string alphabetically, or remove dupe chars?
Message-ID:  <ef10de9a0604251540p6461bfedgf788d500a81e7190@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
basically what I want to do:

my @wordlist =3D (letter, remember, alphabetically);
## some whizbang code that changes words like
## "letter" to "eelrtt", remember to beeemmrr,
## and alphabetically to aaabcehilllpty.
@foobar =3D~ tr///cs; #hmm, doesn't work.
print "@wordlist\n";

Hmm, that's broke, how about this:

my $wordlist =3D "letter";
## some whizbang regex that removes dupe chars
## from words like "alphabetically" --> "alphbeticy".
print "$wordlist\n";


Thanks.
--
BSD Podcasts @ http://bsdtalk.blogspot.com/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ef10de9a0604251540p6461bfedgf788d500a81e7190>