wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Midterm Exam

Total questions: 55

Worksheet time: 36mins

Name
Class
Date
1.

Any activity that uses computers.

a)

Computing

b)

Processing

c)

Programming

d)

None of the option

2.

The process of preparing a program for execution by initializing device memory with the program's code and data

a)

Computing

b)

Loading

c)

Programming

d)

None of the option

3.

The act of creating instructions for a computer to carry out.

a)

Computing

b)

Loading

c)

Programming

d)

None of the option

4.

Takes less code to get things done

a)

Interpreter

b)

Compiler

c)

Printer

d)

None of the option

5.

Faster Development

a)

Interpreter

b)

Compiler

c)

Printer

d)

None of the option

6.

Harder to debug

a)

Interpreter

b)

Compiler

c)

Printer

d)

None of the option

7.

Takes more code to get things done

a)

Interpreter

b)

Compiler

c)

Printer

d)

None of the option

8.

A general purpose _______ programming language

a)

Interpreter

b)

Compiler

c)

Printer

d)

None of the option

9.

Little abstraction with memory

a)

Low Level

b)

Medium Level

c)

High Level

d)

None of the option

10.

High abstraction with memory

a)

Low Level

b)

Medium Level

c)

High Level

d)

None of the option

11.

Flexible syntax and easy to learn

a)

Low Level

b)

Medium Level

c)

High Level

d)

None of the option

12.

Best performance

a)

Low Level

b)

Medium Level

c)

High Level

d)

None of the option

13.

A command line interface

a)

Pseudo code

b)

Algorithm

c)

Console

d)

None of the option

14.

An unambiguous specification of how to solve a class of problems.

a)

Pseudo code

b)

Algorithm

c)

Console

d)

None of the option

15.

a detailed yet readable description of what a computer program must do

a)

Pseudo code

b)

Algorithm

c)

Console

d)

None of the option

16.

A programming paradigm, derived from structured programming

a)

Procedural Programming

b)

Object

oriented

c)

Integrated Development Environment

d)

None of the option

17.

a software application that provides comprehensive facilities to computer programmers for software

a)

Procedural Programming

b)

Object

oriented

c)

Integrated Development Environment

d)

None of the option

18.

Large programs are divided into smaller parts known as objects

a)

Procedural Programming

b)

Object

oriented

c)

Integrated Development Environment

d)

None of the option

19.

Large program are divided into smaller parts known as function

a)

Procedural Programming

b)

Object

oriented

c)

Integrated Development Environment

d)

None of the option

20.

Developer of Python

a)

Guido Van Rossum

b)

Willem Van Gogh

c)

Ronjie Malinao

d)

None of the option

21.

Python 3 was released in the year

a)

2008

b)

1990

c)

2010

d)

None of the option

22.

the process of finding and resolving defects or problems within a computer program

a)

correcting

b)

debugging

c)

tracing

d)

None of the option

23.

A name given to an entity, which distinctly identifies an entity in a program at the time of its execution.

a)

Variable

b)

Identifier

c)

Value

d)

None of the option

24.

The content of some variable

a)

Variable

b)

Identifier

c)

Value

d)

None of the option

25.

Alphanumeric that hold values, like integers, strings of characters, and others.

a)

Variable

b)

Identifier

c)

Value

d)

None of the option

26.

The value a variable when it doesn’t actually have a value.

a)

null

b)

0

c)

none

d)

None of the option

27.

FirstName_LastName="Ronjie Malinao"

a)

With Violation

b)

No Violation

28.

FirstName&LastName="Ronjie Malinao"

a)

With Violation

b)

No Violation

29.

FirstName LastName="Ronjie Malinao"

a)

With Violation

b)

No Violation

30.

1stname="Ronjie"

a)

With Violation

b)

No Violation

31.

print="Ronjie"

a)

With Violation

b)

No Violation

32.

str="ronjie"

a)

With Violation

b)

No Violation

33.

day="Saturday"

a)

With Violation

b)

No Violation

34.

Variables used for whole numbers

a)

Integer

b)

Complex

c)

Float

d)

Boolean

e)

String

35.

Variables that is represented by complex class. It is specified as (real part) + (imaginary part)j

a)

Integer

b)

Complex

c)

Float

d)

Boolean

e)

String

36.

Variables used to store real numbers.

a)

Integer

b)

Complex

c)

Float

d)

Boolean

e)

String

37.

Variables used to store True or False

a)

Integer

b)

Complex

c)

Float

d)

Boolean

e)

String

38.

Variables used to store text or characters

a)

Integer

b)

Complex

c)

Float

d)

Boolean

e)

String

39.

identify the variable type

numbers= {1: isa ', 2: dalawa ', 3: tatlo '}

a)

Dictionary

b)

List

c)

Tuple

d)

None of the above

40.

identify the variable type

Subjects = ["Prog1", "PE2", "Ethics"]

a)

Dictionary

b)

List

c)

Tuple

d)

None of the above

41.

identify the variable type

Subjects = ("Prog1", "PE2", "Arts")

a)

Dictionary

b)

List

c)

Tuple

d)

None of the above

42.

The datatype is identified when the program runs

a)

True

b)

False

43.

Variables can be reassigned at any time

a)

True

b)

False

44.

The original output formatting of python

a)

% formatting

b)

str.format ()

c)

f string format

d)

None of the above

45.

It uses normal function call syntax and is extensible through the format() method

a)

% formatting

b)

str.format ()

c)

f string format

d)

None of the above

46.

or 'F'. These strings may contain replacement fields, which are

expressions delimited by curly braces {}.

a)

% formatting

b)

str.format ()

c)

f string format

d)

None of the above

47.

Causes the subsequent character sequence to “escape” its usual meaning.

a)

% formatting

b)

str.format ()

c)

f string format

d)

None of the above

48.

What will be the output of the following code?

x = 8

y = 3

r = x - y

y = 2

print(r)

(a)  

49.

What will be the output of the following code?

x = 14

y = 3

print(x // y)

(a)  

50.

What will be the output of the following code?

x = 14

y = 3

print(x % y)

(a)  

51.

What will be the output of the following code?

x = 3

y = 2

print(x ** y)

(a)  

52.

What will be the output of the following code?

x = 5

y = 2

print(f"{x / y}")

(a)  

53.

What will be the output of the following code?

x = 5

y = 5

print(x * y * x)

(a)  

54.

What will be the output of the following code?

x = 5

y = 5

print(x + y + x + y)

(a)  

55-60.

Discount Computation Program

This is a discount computation program; debug the code to produce the correct result

#1 prize=int(input("Enter price: "))

#2 discount = int(input("Enter discount %: "))

#3 discount = price ** discount

#4 discount = discount % 100

#5 total = price + discount

#6 print("Total less discount: ",total)

#7 payment = float(input("Payment: "))

#8 change = total - payment

#9 print(f"Change:",change)

55.

what is the correct variable name

prize=int(input("Enter price: "))

a)
price
b)

total

c)

cost

d)

none of the above

56.

What is the correct operator

discount = price ** discount

a)
*
b)

+

c)

-

d)

/

57.

what is the correct operator

discount = discount % 100

a)
/
b)

*

c)

-

d)

+

58.

what is the correct variable name

prize=int(input("Enter price: "))

a)
price
b)

cost

c)

total

d)

none of the above

59.

What is the correct code

change = total - payment

a)

change = total - payment

b)

change = payment - total

c)

total = change - total

d)

total = payment - change

60.

What is the correct code

print(f"Change:",change)

a)

print("Change:',change)

b)

print(f"Change: change")

c)

print(f"Change: {change}")

d)

print("Change: change")

e)

print(f"Change:"%change)