#!/usr/bin/env perl use warnings; use strict; use Lingua::JA::Numbers; use Lingua::JA::Moji 'kana2romaji'; # The following line sets the output encoding to UTF-8. binmode STDOUT, ":encoding(utf8)"; # To get output in EUC-JP, uncomment (remove the leading #) the # following line, and comment the one above. #binmode STDOUT, ":encoding(EUC-JP)"; # The following parameters control the start and the end of the # generated Japanese output numbers. my $first = 1; my $last = 1000; for my $number ($first..$last) { my $kanji = num2ja ($number, {style => 'kanji'}); my $kana = num2ja ($number, {style => 'hiragana'}); my $romaji = kana2romaji ($kana, {style => 'hepburn'}); # Adjust the following format to produce desired output. print <