- web.groovymark@gmail.com
- December 17, 2024
Question 01
What are the basic instruction types of a computer program?
a) Input, output, process
b) Input, storage, output
c) Fetch, decode, execute
d) Input, process, output
Correct Answer: d) Input, process, output
Explanation: A computer program typically involves three basic instructions: input, process, and output. The input gathers data, processing manipulates it, and output delivers the result.
Question 02
What is a variable in programming?
a) A constant that holds a fixed value
b) A data type that holds different types of data
c) A reference to data whose value can change during program execution
d) A static data storage
Correct Answer: c) A reference to data whose value can change during program execution
Explanation: A variable refers to data that programs use, and its value can change as the program runs, hence the name "variable."
Question 03
What is the equation for a triangle’s area?
a) Length x Width / 2
b) Height x Width
c) Base x Height / 2
d) Radius x 2
Correct Answer: c) Base x Height / 2
Explanation: The area of a triangle is calculated by multiplying its base by its height, then dividing by 2.
Question 04
How do you find the average of a set of numbers?
a) Sum the numbers and multiply by the total number of values
b) Multiply the sum of numbers by the number of values
c) Subtract the highest and lowest values from the sum
d) Sum the numbers and divide by the total number of values
Correct Answer: d) Sum the numbers and divide by the total number of values
Explanation: The average is found by adding all the numbers together and then dividing by the number of values in the set.
Question 05
What is computational thinking?
a) Creating a computer algorithm
b) Debugging a program
c) Creating a sequence of instructions to solve a problem
d) Optimizing code
Correct Answer: c) Creating a sequence of instructions to solve a problem
Explanation: Computational thinking involves formulating problems and their solutions in a way that a computer can execute the steps efficiently.
Question 06
What is an algorithm?
a) A type of variable
b) A complex data structure
c) A sequence of instructions that solves a problem
d) A method of processing user inputs
Correct Answer: c) A sequence of instructions that solves a problem
Explanation: An algorithm is a step-by-step sequence of instructions designed to perform a specific task or solve a particular problem.
Question 07
What is a flowchart?
a) A text-based diagram
b) A graphical language for creating programs
c) A software design tool
d) A memory management system
Correct Answer: b) A graphical language for creating programs
Explanation: A flowchart is a diagram that represents a process, showing the steps using various shapes and arrows to demonstrate the flow of control.
Question 08
What is a program?
a) A hardware component of a computer
b) A list of statements that execute one at a time
c) A graphical user interface
d) A data storage method
Correct Answer: b) A list of statements that execute one at a time
Explanation: A program is a collection of instructions or statements executed by the computer to perform a specific task.
Question 09
What tool runs a program’s statements?
a) Compiler
b) Debugger
c) Interpreter
d) Flowchart
Correct Answer: c) Interpreter
Explanation: An interpreter executes program instructions one at a time, as opposed to a compiler, which translates the entire program before execution.
Question 10
What is a specific action in a program called?
a) Function
b) Statement
c) Object
d) Algorithm
Correct Answer: b) Statement
Explanation: A statement is an instruction in a program that performs a specific action, such as assigning a value to a variable or calling a function.
Question 11
What shape is used for an input/output statement in a flowchart?
a) Circle
b) Rectangle
c) Diamond
d) Parallelogram
Correct Answer: d) Parallelogram
Explanation: In a flowchart, a parallelogram is used to represent input or output operations.
Question 12
What represents a new line in programming?
a) \n
b) \t
c) /n
d) /t
Correct Answer: a) \n
Explanation: The escape sequence "\n" is used in programming languages to create a new line in the output.
Question 13
What is a comment in a program?
a) Code that is executed
b) A syntax error
c) Text added by the programmer for human understanding
d) A variable name
Correct Answer: c) Text added by the programmer for human understanding
Explanation: Comments are added to code for clarity and are ignored by the program during execution. They help others understand the code better.
Question 14
What should not include whitespace in programming?
a) Keywords
b) Variable names and digits of a number
c) Functions
d) Loops
Correct Answer: b) Variable names and digits of a number
Explanation: Variable names and digits in numbers should not include any whitespace, as this would create a syntax error in most programming languages.
Question 15
When did the industrial age start?
a) Late 1600s
b) Late 1700s
c) Early 1800s
d) Late 1900s
Correct Answer: b) Late 1700s
Explanation: The industrial age began in the late 1700s with the advent of machinery and manufacturing processes.
Question 16
When did the information age start?
a) 1980s
b) 1990s
c) 2000s
d) 2010s
Correct Answer: b) 1990s
Explanation: The information age, marked by the rise of the internet and computer technology, began in the 1990s.
Question 17
What is an embedded computer?
a) A standalone computer
b) A computer inside another device
c) A desktop computer
d) A cloud-based system
Correct Answer: b) A computer inside another device
Explanation: Embedded computers are found within other devices, such as cars, TVs, and home appliances, performing dedicated functions.
Question 18
What is a character in programming?
a) A block of code
b) A letter, symbol, or digit
c) A file type
d) A data structure
Correct Answer: b) A letter, symbol, or digit
Explanation: A character represents a single letter, number, or symbol in text-based data.
Question 19
What does ASCII stand for, and when was it developed?
a) American Standard Code for Internet Interchange, 1965
b) American Standard Code for Information Interchange, 1963
c) Automated Standard Code for Information Interchange, 1970
d) American Systematic Code for Input Interchange, 1960
Correct Answer: b) American Standard Code for Information Interchange, 1963
Explanation: ASCII is a character encoding standard developed in 1963 to represent text in computers and communication devices.
Question 20
How many bits per code does ASCII use?
a) 6 bits
b) 7 bits
c) 8 bits
d) 9 bits
Correct Answer: b) 7 bits
Explanation: ASCII uses 7 bits to represent characters, allowing for 128 possible characters.