Voting

Category

real language

Bookmarking

Del.icio.us Digg Diigo DZone Earthlink Google Kick.ie
Windows Live LookLater Ma.gnolia Reddit Rojo StumbleUpon Technorati

Language DHTML (Duo html)

(Webscripting language of Duo NV)

Date:01/12/06
Author:Kevin Velghe
URL:http://www.duo.be
Comments:0
Info:http://www.duo.be
Score: (3.14 in 7 votes)
<$- Duo HTML -$>
<html>
<head>
	<title>99 Bottles of Beer</title>
</head>
<body>
	<$SET looper 100>
	<$LOOP looper>
		<$ESET nr 100>
		<$CALC nr - $looper.#>
		<$ESET nr $nr.atoi()>
		<$ESET nrnext $nr>
		<$CALC nrnext - 1>
		<$ESET nrnext $nrnext.atoi()>
		<$IF nr = 0>
			No more bottles of beer on the wall, no more bottles of beer.<br>
			Go to the store and buy some more, 99 bottles of beer on the wall.<br>
		<$ELSE>
			<$IF nr > 1><$SET bottles "bottles"><$/IF>
			<$IF nr = 1><$SET bottles "bottle"><$/IF>
			<$DVAL0 nr> <$VAL bottles> of beer on the wall, <$DVAL0 nr> <$VAL bottles> of beer.<br>
			Take one down and pass it around, 
			<$IF nrnext > 0>
				<$IF nrnext > 1><$SET bottles "bottles"><$/IF>
				<$IF nrnext = 1><$SET bottles "bottle"><$/IF>
				<$DVAL0 nrnext> <$VAL bottles>
			<$ELSE>
				no more bottles
			<$/IF>
			of beer on the wall.<br>
		<$/IF>
		<br>
	<$/LOOP>
</body>
</html>

Download Source | Write Comment

Alternative Versions

Comments

Download Source | Write Comment

Add Comment

Please provide a value for the fields Name, Comment and Security Code.
This is a gravatar-friendly website.
E-mail addresses will never be shown.
Enter your e-mail address to use your gravatar.

Please don't post large portions of code here! Use the form to submit new examples or updates instead!

Name:

eMail:

URL:

Security Code:
  
Comment: