99 бутылок: ASP (JScript и JavaScript), Parser
10. ASP JScript и JavaScript. Одновременно. Первый — серверный язык, второй — клиентский. Испытано под IE 5.0, Opera 5.01, Netscape 4.75, Netscape 6.0 и IIS5.
<!-- <%@ LANGUAGE = JScript %>
<% //>
//</%> --> <SCRIPT LANGUAGE=JavaScript>
for (k = ' of beer on the wall',o='', i = 99; i>0; i--)
{
a = i+' bottle'+(i-1?'s':'')
o+= a+k+', '+a+' of beer...<BR>'+
'Take one down, pass it around.<BR>'+
(i-1?i-1:'No ')+' bottle'+(i-2?'s':'')+k+'.'+
'<BR><BR>'
}
o+= 'No more bottles of beer...<br>'+
'Go to the store and buy some more...<br>'+
'99 bottles of beer.'
if (typeof(document)!='undefined') document.write (o); else
if (typeof(Response)!='undefined') Response.Write (o)
// </SCRIPT> <!-- // < %> -->
9. Parser (втрой версии) студии Артемии Лебедева. Предпроцессор для генерации Веб-страниц «на лету».
^var[i;99]
^while[i>0;
^var[i] bottle^if[i!=1;s;] of beer on the wall, ^var[i]
bottle^if[i==1;s;] of beer.<BR>
Take one and pass it around,<BR>
^var[i;-;1]
^if[i;^var[i];No] bottle^if[i!=1;s;] of beer on the wall.<BR>
<BR>
]
No more bottles of beer...<BR>
Go to the store and buy some more...<BR>
99 bottles of beer.