PYTHON chapter 1-4

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/69

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

70 Terms

1
New cards

Computer Hardware Components

Physical parts of a computer that perform tasks (input, processing, output, storage).

2
New cards

Execute

Perform instructions in a program.

3
New cards

Microprocessor

The CPU, which processes data and executes instructions.

4
New cards

Main Memory (RAM)

Temporary memory used during active processing.

5
New cards

Secondary Memory

Long-term data storage (e.g., hard drive).

6
New cards

Input

Devices that send data to the computer (e.g., keyboard).

7
New cards

Output

Devices that display results (e.g., monitor).

8
New cards

Operating System (OS)

Software that manages hardware and system resources.

9
New cards

Utility Program

Software that performs specific maintenance tasks (e.g., antivirus).

10
New cards

Program

A set of instructions for a computer to follow.

11
New cards

Software

Programs and operating systems that run on hardware.

12
New cards

Programmer

Person who writes and tests computer programs.

13
New cards

String Literal

Sequence of characters in quotes.

14
New cards

Numeric Literal

Number used in a program.

15
New cards

String

Text data type.

16
New cards

Numeric

Number data type (e.g., int, float).

17
New cards

Compiler

Translates source code into machine code all at once.

18
New cards

Garbage Collection

Automatic memory cleanup in some programming languages.

19
New cards

Binary/Boolean

Data with two values (0/1, True/False).

20
New cards

Machine Language

Binary code directly understood by a computer.

21
New cards

Interpreter

Translates and executes code line by line.

22
New cards

Assembly Language

Low-level code with symbolic instructions.

23
New cards

High-Level Language

Programming languages closer to human language (e.g., Python).

24
New cards

Source Code

The original code written by a programmer.

25
New cards

Script

A program executed without compilation.

26
New cards
27
New cards

Flowchart

Diagram that shows the flow of an algorithm.

28
New cards

Pseudocode

Simplified, informal code-like description of a program.

29
New cards

Algorithm

Step-by-step instructions to solve a problem.

30
New cards

Keywords

Reserved words in a programming language.

31
New cards

Bit

Smallest unit of data (0 or 1).

32
New cards

Byte

Group of 8 bits.

33
New cards

ASCII

Character encoding standard.

34
New cards

Data Type

Defines the kind of data (e.g., int, string).

35
New cards

Float

Decimal number data type.

36
New cards

Integer

Whole number data type.

37
New cards

Function

A reusable block of code performing a task.

38
New cards

Calling a Function

Executing a function.

39
New cards

Operator

Symbol that performs operations (e.g., +, -).

40
New cards

Variable

Named memory location that stores data.

41
New cards

Memory Address

Location where a variable is stored.

42
New cards

camelCase

Naming convention where the first word is lowercase, and subsequent words are capitalized.

43
New cards

Exception

An error that disrupts program execution.

44
New cards

Escape Characters

Special characters preceded by \ (e.g., \n).

45
New cards

Concatenation

Joining strings together.

46
New cards

f-string

Formatted string for embedding variables.

47
New cards

Precision Designator

Controls decimal places in float formatting.

48
New cards

Type Designator

Specifies data type in formatting (e.g., d for integer).

49
New cards

Alignment Designator

Specifies text alignment in formatted output.

50
New cards
51
New cards

range() Function

Generates a sequence of numbers.

52
New cards

if-elif-else

Conditional branching structure.

53
New cards

Short Circuit Evaluation

Stops evaluation once the outcome is determined.

54
New cards

and/or/not Operators

Logical operators used in decision-making.

55
New cards

Booleans

Data type with True/False values.

56
New cards
57
New cards

Loop

Repeats a block of code.

58
New cards

While Loop

Repeats while a condition is true (pretest loop).

59
New cards

For Loop

Iterates over a sequence.

60
New cards

Conditional Loop

Repeats based on a condition.

61
New cards

Sentinels

Special values that signal loop termination.

62
New cards

Input Validation Loop

Ensures valid input before proceeding.

63
New cards

Nesting

Placing loops inside loops.

64
New cards

Infinite Loop

Loop with no termination condition.

65
New cards

Count-Controlled Loop

Loop with a predetermined number of iterations.

66
New cards

GIGO

"Garbage In, Garbage Out" – poor input leads to poor output.

67
New cards

break

Exits a loop prematurely.

68
New cards

continue

Skips to the next iteration of a loop.

69
New cards

else (Loop)

Executes after loop ends if not terminated by break.

70
New cards

Top-Down Design

Breaking a problem into smaller parts.