Flow Control - Branch Statements - Exercises
Chapter02
Task Name - Flow Control
Check-in Requirements
Assignment 1
Write a user login authentication program. For example, the username is “Albert” and the password is “1”. Ask the user to enter the username and password separately for authentication; if the user’s input is correct, show that the login succeeded, otherwise show that the username or password is wrong.
Assignment 2
Write an age-guessing game for the user. Define the user’s age in advance; if the user’s guess is too high, give a “too high” hint; if the guess is too low, give a “too low” hint; otherwise the user has guessed correctly, and give a “correct” message as well.
Requirements:
1, Write down your own approach to solving the problem, in any form: written description, flowchart, or mind map
2, After finishing the assignment, take a screenshot & upload the image to check in.
3, Note: after checking in, share it in the study group and @ the teaching assistant to have your code checked