Acme-Flip

 view release on metacpan or  search on metacpan

lib/Acme/Flip.pm  view on Meta::CPAN

	"<"	=> ">",
	">"	=> "<",
	"_"	=> "\x{203e}",
);

sub flip
{
	$_ = shift;
	my $width = (shift or 80);
	while (s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e) {};
	join ("\n", map {
		sprintf "%${width}s", join '', map {
			$_ = lc $_; exists $table{$_} ? $table{$_} : $_
		} reverse split (/\B|\b/, $_)
	} reverse split (/\n/, $_))."\n";
}

1;

=head1 NAME

Acme::Flip - Replace alphanumeric characters in text with ones that look flipped



( run in 1.006 second using v1.01-cache-2.11-cpan-49f99fa48dc )