Acme::Orisnek
Acme::Kensiroはencodeだけでdecodeが無いよ!
って事で作ってみました。
package Acme::Orisnek;
use strict;
use warnings;
use utf8;
use base qw/Exporter/;
our @EXPORT = 'orisnek';
our $VERSION = 0.01;sub orisnek {
my $自転車 = shift;
utf8::decode($自転車) unless utf8::is_utf8($自転車);
return 0 unless $自転車 =~ /^[あた]+$/;$自転車 =~ s/た/0/g;
$自転車 =~ s/あ/1/g;my $じてんしゃ = (length($自転車) % 8);
$じてんしゃ = 8 - $じてんしゃ if $じてんしゃ;
$自転車 = '0' x $じてんしゃ . $自転車;my $ジテンシャ = unpack("C", pack("B8", $自転車));
return $ジテンシャ;
}1;
__END__=head1 NAME
Acme::Orisnek - kensiro-sinsu decoder
=head1 SYNOPSIS
use Acme::Orisnek;
orisnek('あたたたた'); # => 16=head1 DESCRIPTION
kensiro-sinsu decoder.
=head1 SEE ALSO
L<Acme::Kensiro>, L<http://www.asahi-net.or.jp/~rc4t-ishr/kensiro.html>
=head1 AUTHOR
Kazuhiro Osawa
=head1 LICENCE
This module is free software; you can redistribute it and/or
modify it under the same terms as Perl itself. See L.
自転車漕ぎながらデコードします。
なんかAcme::Kensiroは8bit演算しか出来ない希ガス。
まだ未読のFeed沢山有るなぁ。。。