>>29258229I found this and stuffs
<pre class="prettyprint"> program ninetyninebottles
integer bottles
* 99 Bottles of Beer, as implemented in FORTRAN 77
* Written by Alex Ford - [email protected]<script type="text/javascript">
/* <![CDATA[ */
(function(){try{var s,a,i,j,r,c,l=document.getElementById("__cf_email__");a=l.className;if(a){s='';r=parseInt(a.substr(0,2),16);for(j=2;a.length-j;j+=2){c=parseInt(a.substr(j,2),16)^r;s+=String.fromCharCode(c);}s=document.createTextNode(s);l.parentNode.replaceChild(s,l);}}catch(e){}})();
/* ]]> */
</script>
* Notable feature: Arithmetic IF statement
bottles = 99
* Format statements
1 format (I2, A)
2 format (A)
3 format (I2, A, /)
4 format (A, /)
* First 98 or so verses
10 write (*,1) bottles, ' bottles of beer on the wall,'
write (*,1) bottles, ' bottles of beer.'
write (*,2) 'Take one down, pass it around...'
if (bottles - 1 .gt. 1) then
write (*,3) bottles - 1, ' bottles of beer on the wall.'
else
write (*,3) bottles - 1, ' bottle of beer on the wall.'
end if
bottles = bottles - 1
if (bottles - 1) 30, 20, 10
* Last verse
20 write (*,1) bottles, ' bottle of beer on the wall,'
write (*,1) bottles, ' bottle of beer.'
write (*,2) 'Take one down, pass it around...'
write (*,4) 'No bottles of beer on the wall.'
30 stop
end
</pre>