Lingua::TR::Numbers - Converts numbers into Turkish text.



NAME

Lingua::TR::Numbers - Converts numbers into Turkish text.


SYNOPSIS

   use Lingua::TR::Numbers qw(num2tr num2tr_ordinal);

   my $x = 234;
   my $y = 54;
   print "Bugün yapman gereken ", num2tr($x), " tane işin var!\n";
   print "Yarın annemin ", num2tr_ordinal($y), " yaşgününü kutlayacağız.\n";

prints:

   Bugün yapman gereken iki yüz otuz dört tane işin var!
   Yarın annemin elli dördüncü yaşgününü kutlayacağız.


DESCRIPTION

Lingua::TR::Numbers turns numbers into Turkish text. It exports (upon request) two functions, num2tr and num2tr_ordinal. Each takes a scalar value and returns a scalar value. The return value is the Turkish text expressing that number; or if what you provided wasn't a number, then they return undef.

This module can handle integers like ``12'' or ``-3'' and real numbers like ``53.19''.

This module also understands exponential notation -- it turns ``4E9'' into ``dört çarpı 10 üzeri dokuz''). And it even turns ``INF'', ``-INF'', ``NaN'' into ``sonsuz'', ``eksi sonsuz'' and ``sayı-değil'' respectively.

Any commas in the input numbers are ignored.


FUNCTIONS

You can import these one by one or use the special :all tag:

   use Lingua::TR::Numbers qw(num2tr num2tr_ordinal);

or

   use Lingua::TR::Numbers qw(:all);

num2tr

Converts the supplied number into Turkish text.

num2tr_ordinal

Similar to num2tr, but returns ordinal versions .


LIMIT

This module supports any numbers upto 999 decillion (999*10**33). Any further range is currently not in commnon use and is not implemented.


SEE ALSO

the Lingua::EN::Numbers manpage. http://www.radikal.com.tr/haber.php http://en.wikipedia.org/wiki/Names_of_large_numbers.

See NumbersTR.pod (bundled with this distribution) for the Turkish translation of this documentation.


CAVEATS

This module' s source file is UTF-8 encoded (without a BOM) and it returns UTF-8 values whenever possible.

Currently, the module won't work with any Perl older than 5.6.


AUTHOR

Burak Gürsoy, <burak&64;cpan.org>


COPYRIGHT

Copyright 2006 Burak Gürsoy. All rights reserved.

This module is based on and includes modified code portions of Sean M. Burke's Lingua::EN::Numbers.

Lingua::EN::Numbers is Copyright (c) 2005, Sean M. Burke.


LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

 Lingua::TR::Numbers - Converts numbers into Turkish text.