Comp 1 Exam

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/43

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 5:14 AM on 9/22/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

44 Terms

1
New cards

ALU

Arithmetic & Logic Unit: Part of the CPU that performs mathematical operations

2
New cards

CPU

Central Processing Unit: most important component; the part of the computer that actually runs programs

3
New cards

Logic Error

is a bug that causes a program to operate incorrectly but does not terminate or crash

4
New cards

Syntax Error

detected by the compiler and the program does not run

5
New cards

Preprocessor Directive

lines in a program that being with the character #, instructions for the preprocessor, #<iostream>

6
New cards

Reserved Words

words that already have a role in coding

7
New cards

Combined Assignment Operator

a combined assignment operator performs an operation on variable and assigns the result back to that variable in a single statement

8
New cards

Compiler

software program that translates code written in a high-level programming language to a lower level programming language

9
New cards

Executable Code

machine language instructions ready to run, including any needed-run-time library routines

10
New cards

Control Unit

Part of the CPU that coordinates all the computer’s operations

11
New cards

Source Code

Statements written by the programmer

12
New cards

Declaration

is a statement that introduces an identifier (such as a variable, function, class, or type) to the compiler or interpreter, specifying its name and type without necessarily allocating memory or providing implementation details.

13
New cards

Comment

is a piece of text that is ignored

14
New cards

Constant

refers to a value that remains unchanged throughout the execution of a program.

15
New cards

Overflow

occurs when the result of a computation exceeds the range that can be represented within a fixed number of bits.

16
New cards

High-Level Language

programming language closer to human language, such as C++, Python, or Javva

17
New cards

Low-Level Langauge

Used for communication directly with hardware, such as machine language or Assembly

18
New cards

Assignment

an assignment is the process of giving a value to a variable, allowing the program to store and manipulate data

19
New cards

Syntax

refers to the set of rules that defines the combination of symbols that are considered to be correct

20
New cards

Initialization

the preparation of a computer or similar device for operation, in which diagnostic tests are run and the operating system is loaded

21
New cards

RAM

Random Access Memory

22
New cards

Underflow

refers to a condition where a calculation results in a value that is smaller than the smallest representable number in a given data type.

23
New cards

Bit

1

24
New cards

Byte

8

25
New cards

long

like a line

26
New cards

int

integer no decimal

27
New cards

short

small amount

28
New cards

double

the biggest

29
New cards

float

the decimal can move

30
New cards

char

single character

31
New cards

string

multiple chars, text, longer than a double but reads it as texts, can’t hold number operations

32
New cards

bool

true or false

33
New cards

integer Division

discard any remainder

34
New cards

Valid Variable naming

 no funky characters, no reserved words, has to start with a letter or underscore, no blank space between the words or characters.

35
New cards

setw

set the width of the output field

36
New cards

setprecision

like how many spots behind a decimal you want

37
New cards

fixed

the decimal point doesnt move

38
New cards

show point

to control the output format of floating-point numbers.

39
New cards

How do you make a variable

int ____ = __;

40
New cards

in put

»

41
New cards

out put

«

42
New cards

Division in code

int main() {
int a = 7, b = 2;
int result = a / b; // Integer division
cout << "7 / 2 = " << result << endl; // Output: 3
return 0;

43
New cards

the ending sequence

\end, /n, endl

44
New cards

Cin

// Output prompt using cout
cout << "Enter your name: ";
cin >> name; // Reads a single word into 'name'

cout << "Enter your age: ";
cin >> age; // Reads an integer into 'age'