
Lesson Variables
Presentation
•
Computers
•
9th Grade
•
Practice Problem
•
Medium
Laila Zuaiter
Used 19+ times
FREE Resource
7 Slides • 8 Questions
1
Swiftplayground
Week 2
Computer Science - CSC400
2
Define variables as a value that can change, depending on conditions or on information passed to the program under the Swift programming platform.
Identify different types of variables used to store data in Swift programming platform and the way to parse data between them.
Declare a variable and assign a value to it using the Swift programming platform syntax to hold a specific data within a program
3
Declare Constants using let command in Swift Programming platform to hold a non-changing variable value.
Use the assignment operator (=) to assign a new value to a variable in a program that matches its defined data type
Identify the scope of the local variables in a programming as an indication of how accessible a variable is to a function or another call within the same program.
Perform arithmetic, increment, decrement, comparison between variables and logical operators to perform different operations on variables
4
Variable : A named container that stores a value. The value can change over time.
5
Multiple Choice
Which of the following is the correct definition of a variable?
A function that performs calculations
A storage location in memory with a specific name
A type of loop that repeats actions
A collection of data items
6
Types of variable
let name = "Ahmad". // String
var age = 15 // Integer
var height = 1.6 // float
var isOnClosedSwitch = true //Boolean
7
Multiple Choice
Which of the following types is a String?
let name = "Sara"
var age = 15
let speed = 80.5
var isBlocked = false
8
Multiple Choice
Which of the following types is a float?
let name = "Sara"
var age = 15
let speed = 80.5
var isBlocked = false
9
Multiple Choice
Which of the following types is a boolean?
let name = "Sara"
var age = 15
let speed = 80.5
var isBlocked = false
10
Multiple Choice
Which of the following types is an integer?
let name = "Sara"
var age = 15
let speed = 80.5
var isBlocked = false
11
Declare a constant
Constant: A named Container that stores a value that can't be changed
example:
let name = "Amna"
Variable : a variable that can be modified later
example :
var EnglishMark = 90
12
Multiple Choice
In Swift programming, what keyword is used to declare a variable that can be modified later?
const
var
let
mut
13
Multiple Choice
How do you declare a constant in Swift?
constant myValue = 10
static myValue = 10
let myValue = 10
final myValue = 10
14
Swift playground
Solve Swift playground :
Keeping Track
Bump up the Value
Incrementing the Value
15
Open Ended
Search on the internet and write what are the rules of Naming variable?
Swiftplayground
Week 2
Computer Science - CSC400
Show answer
Auto Play
Slide 1 / 15
SLIDE
Similar Resources on Wayground
10 questions
Evidence of Evolution
Presentation
•
9th Grade
10 questions
Solving a System of Equations using Substitution
Presentation
•
9th Grade
11 questions
Biodiversity and Human Impacts
Presentation
•
9th Grade
11 questions
SKILLS OF ENTREPRENEURS
Presentation
•
9th Grade
11 questions
Point-Slope Form
Presentation
•
9th Grade
11 questions
ethos pathos logos
Presentation
•
9th Grade
10 questions
REVISÃO PROVA PARANÁ
Presentation
•
9th Grade
10 questions
Macromolecules
Presentation
•
9th Grade
Popular Resources on Wayground
10 questions
Safety Day 2026 – Student Review
Quiz
•
9th Grade
21 questions
Continents and Oceans
Quiz
•
6th Grade
20 questions
Parts of Speech
Quiz
•
5th Grade
16 questions
Subject & Predicate
Quiz
•
5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
12 questions
Map Skills
Quiz
•
3rd Grade
22 questions
Continents and Oceans
Quiz
•
5th Grade
15 questions
Rounding Decimals
Quiz
•
5th Grade