Vai al contenuto

Week 4

Text Challenge 1 Discussione

Write a program to replace all occurrences of the word ‘red’ with ‘blue’ in the following sentence:

The red car was going incredibly fast when it passed the red stop sign, before reducing its speed and hitting a lorry carrying red paint.

Text Challenge 2

Ask the user to enter the day, month and year they were born (or any other date) and the computer should then calculate and display the day of the week when they were born.

Hint: Google ‘Doomsday Algorithm’.  Here is a good start.

Graphical Challenge

Write a reaction time program to click on an object when it randomly appears on the GraphicsWindow and display the reaction time.

Lascia un commento

Il tuo indirizzo email non sarà pubblicato. I campi obbligatori sono contrassegnati *

Questo sito usa Akismet per ridurre lo spam. Scopri come i tuoi dati vengono elaborati.