Due: Friday 09/27 10:00am
Submission name: w10_fizzbuzz
Write a processing program withe the following features:
This program will play out the game fizzbuzz by displaying a number or the appropriate text.
- Global Variables:
fizz
,buzz
,count
(allint
)
setup
- Set the screen size to 300x300.
- Set the
frameRate
to 30fps. - Perform any functions needed to set your text defaults (see below for more info).
- Initialize your global variables:
fizz
should be3
,buzz
should be5
,count
should be0
.
draw
- Clear the screen.
- Increase
count
by one twice a second. - Display:
- FizzBuzz! if
count
is divisible by bothfizz
andbuzz
. - Fizz if
count
is divisible by onlyfizz
. - Buzz if
count
is divisible by onlybuzz
. count
in any other case.
- FizzBuzz! if
- In order to show text or
count
to the screen, you should look at the following functions:
Of course, you can always try to jazz it up