class Coffee { public static void main(String[] args) { // initialize cupsOfCoffee int cupsOfCoffee = 1; // add while loop with counter while(cupsOfCoffee <= 100){ cupsOfCoffee++; System.out.println("Fry drinks cup of coffee #"+cupsOfCoffee); } } }
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter