The new and improved Super Straw will make your drinking experience even better with cooler light displays. Notice that a different light or light display would be turned on every time you take a sip from the straw. It goes like RED-> BLUE -> YELLOW -> YELLOW-BLUE-RED and FADE. The cycle then repeats itself.
However, I encountered a small problem with the fading effect. The lights do not seem to completely turn off in the end.
Then I changed while (brightness > 0 ) to while (brightness >= 0 ) in the beginning of the part of the code that is in charge of the fading effect, then the problem was solved. It seemed that I need to allow the brightness to go to or below 0 to make the lights completely turned off.
link to my code: https://github.com/ross67/IntroToIm/blob/master/Project%20Super%20Straw%202.0.txt