Computer Science 1 Flashcards
What is the purpose of an algorithm?
To provide a step-by-step procedure for solving a problem.
True or False: A variable in programming can hold multiple values at the same time.
False
Fill in the blank: The __________ is the part of the computer that performs calculations and makes decisions.
CPU
What does ‘IDE’ stand for in programming?
Integrated Development Environment
Which data structure uses LIFO (Last In, First Out) principle?
Stack
Multiple Choice: Which of the following is not a programming paradigm? A) Object-oriented B) Functional C) Procedural D) Non-linear
D) Non-linear
What is the main function of an operating system?
To manage computer hardware and software resources.
True or False: A syntax error occurs when the code is logically incorrect.
False
What is the purpose of a compiler?
To translate high-level programming code into machine code.
Fill in the blank: In object-oriented programming, a __________ is a blueprint for creating objects.
Class
What is recursion in programming?
A function that calls itself in order to solve a problem.
Multiple Choice: Which of the following is a type of database? A) Relational B) Linear C) Sequential D) Graphical
A) Relational
What is a primary key in a database?
A unique identifier for a record in a table.
True or False: A linked list can store elements in non-adjacent memory locations.
True
What is the purpose of a firewall?
To protect a network by controlling incoming and outgoing traffic.