Java :: Aufgabe #43 :: Lösung #4
6 Lösungen

#43
99 Bottles of Beer - Selbstständige Lösung
Anfänger - Java
von pocki
- 11.01.2013 um 14:07 Uhr
Programmiere eine eigenständige Lösung zur gängigen Programmier-Übung bzw. Lied 99 Bottles of Beer
Ausgabe:
Ausgabe:
Konsolenausgabe:
99 bottles of beer on the wall, 99 bottles of beer.
Take one down and pass it around, 99 bottles of beer on the wall.
98 bottles of beer on the wall, 98 bottles of beer.
... usw.
#4

von Salute (220 Punkte)
- 30.05.2015 um 20:00 Uhr

public class Bier { public static void main(String[] args) { int flaschen = 99; while (flaschen > 0){ System.out.println(flaschen + " bottles of beer on the wall, "+ flaschen + " bottles of beer. " + "\n Take one down and pass it around, " + flaschen + " bottles of beer on the wall."); --flaschen; } } }
Kommentare:
Für diese Lösung gibt es noch keinen Kommentar
Seite 1 von 0
1