====== 99 bottles of beer ====== ===== workflow ===== 99..1 { auto beer = index; workflow { destruct print ".\n"; print ( beer?= then beer$ else "no more" ), " bottles of beer on the wall"; construct print ( beer?= then ",\n" + beer$ + " bottles of beer.\nTake one down, pass it around, " else "Go to the store and buy some more" ); construct beer? then beer-- else beer : 99; } } 2. Version: howMuch construct code( uint beer ) := print (beer?= then beer$ else "no more" ), " bottles of beer on the wall"; howMuch destruct code( uint beer ) := { howMuch.construct( beer-1 ); print ".\n"; } passIt construct code( uint beer ) { print ( beer?= then ",\n" + beer$ + " bottles of beer.\nTake one down, pass it around, " else "Go to the store and buy some more, " ); } 99..1.workflow { howMuch( index ); passIt( index ); }