



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




Keyword - CORRECT ANSWERS A reserved word (like let, var, func) in Swift that has a predefined meaning and cannot be used for naming. Input - CORRECT ANSWERS Data that is provided to the program from an external source (e.g., keyboard or file). Output - CORRECT ANSWERS Data that the program sends out (e.g., text displayed on the screen). Types - CORRECT ANSWERS Defines the kind of data a value can store (e.g., whole number, decimal, text). Strings - CORRECT ANSWERS An ordered collection of characters used to represent textual data (e.g., "Hello, World"). Double - CORRECT ANSWERS A floating-point type used to store numbers with a decimal component (high precision). Integer - CORRECT ANSWERS A whole number (positive, negative, or zero) with no fractional component. Constant - CORRECT ANSWERS Declared with let; its value is set once and cannot be changed later. Variable - CORRECT ANSWERS Declared with var; its value can be changed after it is initially set.
if vs. else if vs. else - CORRECT ANSWERS Control flow statements used for conditional execution to run different code based on different conditions. Function - CORRECT ANSWERS A self-contained block of code that performs a specific, reusable task. Parameter - CORRECT ANSWERS The name and type defined in a function's declaration to receive an input value. Argument - CORRECT ANSWERS The actual value passed into a function when it is called, corresponding to a parameter. Defining your function - CORRECT ANSWERS Writing the actual structure of the function using the func keyword. Calling your function - CORRECT ANSWERS Executing the function by using its name followed by parentheses containing arguments. Methods - CORRECT ANSWERS Functions that are associated with a specific type (e.g., a class or struct); they perform actions on the data. Properties - CORRECT ANSWERS Constants or variables that are part of a type; they store values associated with an instance.
Arrays - CORRECT ANSWERS An ordered collection of values where all elements must be of the same type. For Loop - CORRECT ANSWERS A control flow statement used to iterate over a sequence (like an array) and execute code for each element. Arrays in Functions - CORRECT ANSWERS Passing an array as an argument to a function or returning an array as the function's output. Initializing Empty Array - CORRECT ANSWERS Creating an array with zero elements, allowing data to be added later (e.g., var data: [String] = []).