Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
(PROG-111A) 43/50
BY: JOSHUA UNGAB
(NOTE: WAG NYO SANA GAMITIN PANG BEBENTA SA IBA
JUSKO. SHARE NYO SA IBA GUYS)
Refer to the code snippet below. Identify what part of a method is shown in each
number (the underlined one).
Read each statement carefully and decide whether it’s TRUE or FALSE.
Answer: False
Refer to the code snippet below. Identify what part of a method is shown in each
number (the underlined one).
GIVEN: int getArea
Answer: foo
Answer: small
Answer: False
TRUE OR FALSE: The value of “val_3” is 3
Answer: FALSE
Answer: barfoo
Refer to the code snippet below. Determine whether the given is a local variable,
instance variable, access modifier or a class name.
Answer: FALSE
Answer: 200
Answer: False
Fill in the blank:
Answer: foo
Refer to the block of codes below. Read each statement carefully and decide whether
it’s TRUE or FALSE.
Answer: TRUE
True or False: Non-procedural programming focuses on how a task is done rather than
on what task should be done.
Answer: False
Refer to the code snippet below. Determine whether the given is a local variable,
instance variable, access modifier or a class name.
True or False: If you are running a program through CLI, the class name and the file
name should be different.
Answer: False
Answer: 6
The “indexOf( )” method returns the first instance of the specified character.
Answer: True
If we change the initial value of num in line 6 to “num = 0”, the println output will be
Answer: 0
Answer: True
True or False: Keywords are Java reserved words which are used as identifier for
interface, constants and constructs.
Answer: True
Refer to the code snippet below. Determine whether the given is a local variable,
instance variable, access modifier or a class name.
True or False: After compiling a Java program through the CLI, run it using the java and
press Enter.
Answer: True
Refer to the program below. Read each statement carefully and write the output for
each line specified.
Answer: 1