I would like to write a simply Java script (native) program which MUST use a while loop and do the following.
- prompts user to enter a colour -
- Then change the background to that colour.
- keep prompting them to enter colour and keep changing the background colour until user does not enter anything in the prompt at which point the WHILE loop ends.
I have seen lot of variations of this tackled by using functions - but I want to achieve this only using WHILE loop.