99 bottles of beer: Difference between revisions

Content added Content deleted
imported>Rowsety Moid
No edit summary
Line 3,708: Line 3,708:
=={{header|EasyLang}}==
=={{header|EasyLang}}==
<syntaxhighlight lang="easylang">
<syntaxhighlight lang="easylang">
proc checkPlural num . word$ .
proc getPlural num . word$ .
word$ = "bottles"
if num = 1
if num = 1
word$ = "bottle"
word$ = "bottle"
else
word$ = "bottles"
.
.
.
.
#
#
for i = 99 step -1 to 1
i = 99
repeat
call checkPlural i pluralWord$
getPlural i bottle$
print i & " " & pluralWord$ & " of beer on the wall"
print i & " " & pluralWord$ & " of beer"
print i & " " & bottle$ & " of beer on the wall"
print i & " " & bottle$ & " of beer"
print "Take one down, pass it around"
print "Take one down, pass it around"
call checkPlural i - 1 pluralWord$
i -= 1
if i - 1 = 0
until i = 0
getPlural i bottle$
print "No more bottles of beer on the wall"
print i & " " & bottle$ & " of beer on the wall"
else
print i - 1 & " " & pluralWord$ & " of beer on the wall"
.
print ""
print ""
.
.
print "No more bottles of beer on the wall"
</syntaxhighlight>
</syntaxhighlight>