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 SPIRES

Date:06/21/05
Author:Richard L. Guertin
URL:http://lindy.stanford.edu/~guertin/
Comments:0
Info:http://www.slac.stanford.edu/library/uspires/
Score: (3.00 in 6 votes)
* BOTTLES.99
; SPIRES Database Manipulation Language
! set noecho
  let bottles = $int(99)
  repeat  ;  Sing the song
     show eval #bottles ' bottles of beer on the wall.  ' #bottles ' bottles of beer.'
     show eval 'Take one down and pass it all around.'
     let bottles = #bottles - 1
     if #bottles > 1 then begin
        show eval #bottles ' bottles of beer on the wall.'
        show eval ' '  ; print blank line
     endb
     else begin  ;  only one left
        show eval 'Only 1 more bottle of beer on the wall!'
        show eval ' '  ; print blank line
        show eval 'Take it down an pass it all around.'
        show eval 'No more bottles of beer on the wall  (Burp).'
        leave  ; terminate the loop
     endb
  until #bottles <= 0
  return

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: