You are on page 1of 4

Republic of the Philippines

Department of Education
Region IV-A CALABARZON
CITY SCHOOLS DIVISION OFFICE OF ANTIPOLO
SAN JOSE NATIONAL HIGH SCHOOL
Science, Technology and Engineering Program

SUMMATIVE EXAM IN TLE-ICT 09

Name______________________________ Year and Sec. _________ Score: ________

MULTIPLE CHOICE
Direction: Choose the letter of the correct answer. Use your answer sheet for your answers.

1. Which of the following is correct syntax for the output "Hello World" in Python?
a. echo("Hello World"); c. p("Hello World")
b. echo "Hello World" d. print("Hello World")

2. Which of the following is correct syntax to insert COMMENTS in Python code?


a. //This is a comment c. /*This is a comment*/
b. #This is a comment d. *This is a comment

3. The statements below are the guidelines in declaring a variable EXCEPT:


a. It must begin with a letter before the c. No special characters.
number. d. Instead of using spaces in variables
b. Variables use spaces. use underscore.

4. What special character is used to define a block of code (body of loop, function etc.) in
Python?
a. Curly braces c. Indentation
b. Parenthesis d. Quotation

5. Which of the following is correct?


a. Comments are for programmers for better understanding of the program.
b. Python Interpreter ignores comment.
c. You can write multi-line comments in Python using triple quotes, either ''' or """.
d. All the above

6. What is the output of the following code?


numbers = [2, 3, 4]
print(numbers)

a. 2, 3, 4 c. [2, 3, 4]
b. 2 3 4 d. [2 3 4]

7. Why python programming is different in naming a variable?


a. Python is a type-inferred language, so you don't have to explicitly define
the variable type.
b. Python is a popular general-purpose programming language.
c. Python is used in machine learning, web development, desktop applications, and many
other fields.
d. Python has a simple, easy-to-use syntax.

8. Why python is friendly-user programming language?


a. Python is a type-inferred language, so you don't have to explicitly define
the variable type.
b. Python is a popular general-purpose programming language.
c. Python is used in machine learning, web development, desktop applications, and many
other fields.
d. Python has a simple, easy-to-use syntax.
9. What do you call to special type of variable whose value cannot be changed?
a. Comment c. Constant
b. Variable d. Print

10. What is the other term of VALUE in a program, it can be a number, string, characters
etc.?
a. Comment d. Print
b. Variable
c. Constant

TRUE OR FALSE.
Directions: Write the word “TRUE” if the statement is correct otherwise “FALSE”.

1. A single-line comment starts and ends in the same line. We use the # symbol to write a
single-line comment.
2. If we write comments in our code, it will be easier for future reference.
3. Always use comments to explain why we did something rather than how we did
something.
4. In computer programming, data types specify the type of data that can be stored inside a
variable.
5. Integers, floating-point numbers and complex numbers fall under Python numbers

6. int - holds signed integers of non-limited length.

7. float - holds floating decimal points and it's accurate up to 15 decimal places.

8. complex - holds complex numbers.


9. List is an ordered collection of similar or different types of items separated by commas
and enclosed within brackets [ ].
10. Constant and variable names should have a combination of letters.

TABLE COMPLETION
Direction: The following are the data types in python, write the correct answer on the
space provided.

Data Types Classes Description


Numeric 21 holds numeric values
22.
23.
String 24. holds sequence of characters
Sequence 25. holds collection of items
26.
27.
28.
Mapping 29. holds data in key-value pair
form
Boolean 30. holds either True or False
Set 31. hold collection of unique
32. items
SUPPLY TYPE.
Directions: Read and understand each problem and supply the missing source code.

Write a Python program that will accept the base and height of a triangle and
compute its area. (33-35)
Source code:
b = ____(____("Input the base : "))
h = ____(____ ("Input the height : "))
area = b*h/2
print(area)

REFLECTION: Complete the sentences below by writing 2-3 sentences each. (36-
40)

A. I Realized that…
B. understand that..

You might also like