Recall & Review
beginner
What is an int in Flutter?
An int is a data type that stores whole numbers without decimals, like 1, 42, or -7.
Click to reveal answer
beginner
How is a double different from an int?
A double stores numbers with decimals, like 3.14 or -0.5, while an int stores whole numbers only.
Click to reveal answer
beginner
What kind of data does a String hold?
A String holds text, like words or sentences, for example: "Hello, Flutter!".
Click to reveal answer
beginner
What values can a bool have?
A bool can only be true or false. It is used for yes/no or on/off decisions.
Click to reveal answer
beginner
Why is it important to use the correct data type in Flutter?
Using the correct data type helps Flutter understand what kind of data you have, so it can store and use it properly without errors.
Click to reveal answer
Which data type would you use to store the number 10?
✗ Incorrect
The number 10 is a whole number, so it should be stored as an int.
What data type is best for storing the text "Flutter Rocks"?
✗ Incorrect
Text like "Flutter Rocks" is stored as a String.
Which data type can only be true or false?
✗ Incorrect
The bool type holds only true or false values.
Which data type would you use for the number 3.1415?
✗ Incorrect
3.1415 has decimals, so it should be stored as a double.
What happens if you try to store text in an int variable?
✗ Incorrect
Storing text in an int variable causes an error because the types don't match.
Explain the difference between int and double data types in Flutter.
Think about numbers with and without decimals.
You got /3 concepts.
Describe when you would use a bool data type in a Flutter app.
Think about simple yes/no questions in your app.
You got /3 concepts.