Ethiopian multiplication: Difference between revisions

Add Plain English
(→‎{{header|IS-BASIC}}: Marked incorrect.)
(Add Plain English)
Line 3,768:
end;
/</lang>
 
=={{header|Plain English}}==
<lang plainenglish>\All required helper routines already exist in Plain English:
\
\To cut a number in half:
\Divide the number by 2.
\
\To double a number:
\Add the number to the number.
\
\To decide if a number is odd:
\Privatize the number.
\Bitwise and the number with 1.
\If the number is 0, say no.
\Say yes.
 
To run:
Start up.
Put 17 into a number.
Multiply the number by 34 (Ethiopian).
Convert the number to a string.
Write the string to the console.
Wait for the escape key.
Shut down.
 
To multiply a number by another number (Ethiopian):
Put 0 into a sum number.
Loop.
If the number is 0, break.
If the number is odd, add the other number to the sum.
Cut the number in half.
Double the other number.
Repeat.
Put the sum into the number.</lang>
{{out}}
<pre>
578
</pre>
 
=={{header|Powerbuilder}}==
1,808

edits