3 # This file is part of NIT ( http://www.nitlanguage.org ).
4 # This program is public domain
6 # Task: Ethiopian Multiplication
7 # SEE: <http://rosettacode.org/wiki/ethiopian_multiplication>
9 # Generic non-robust version.
10 module ethiopian_multiplication
12 fun ethiopian
(x
, y
: Int): Int
26 if not x
.is_even
then sum
+= y
32 var words
= gets
.split
(" ")
33 print ethiopian
(words
[0].to_i
, words
[1].to_i
)