Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

Day 22: Project 2: Guess The Flag, Part Three

Follow along at https://www.hackingwithswift.com/100/swiftui/22.

📒 Field Notes

This day covers Part Three of Project 2: Guess The Flag in the 100 Days of SwiftUI Challenge. (Project files can be found in the directory for Part One.)

In addition to recapping the material covered during the project's other days, Day 18 focuses on extending the project according to a set of challenges.

🥅 Challenges

Challenge 1

Add an @State property to store the user’s score, modify it when they get an answer right or wrong, then display it in the alert.

  • (Already Covered 🙂)

Challenge 2

Show the player’s current score in a label directly below the flags.

Challenge 3

When someone chooses the wrong flag, tell them their mistake in your alert message – something like “Wrong! That’s the flag of France,” for example.

📸 Screenshots