Hcic 2021

Download as pdf or txt
Download as pdf or txt
You are on page 1of 20

Question (1)

Observe the following gear structure carefully. Which of the following


statements is true?

X B

C
A D

(A) The structure is moving smoothly with all gears in action.


(B) The structure should move only if gear B is removed.
(C) The structure should move only if gear C is removed.
(D) The structure is unable to move.
Question (2)

Which of the following light sensor configurations is optimal for the robot to
follow a curve path?

Light Sensor

Wheel

(A) (C)

(B) (D)
Question (3)

Given that the Gear with 40 teeth (t) makes 1 complete revolution in 1 minute, what
is the number of revolution per minute (rpm) for each gear in the following gear
configuration?

Gear with 24t (rpm) Gear with 20t (rpm) Gear with 8t (rpm)
(A) 2.66 3 6
(B) 64 60 48
(C) 1.66 2 5
(D) 16 20 32
Question (4)

The following program is written to move the robot forward until a light sensor detects
the colour black on the ground. However, the program is not working as expected.
Assuming the robot is correctly built, identify which line(s) of the program you need
to alter for the program to function correctly.

1 | set colour to colour sensor reading


2 | while touch sensor is not pressed
3 | set left motor to speed 80
4 | set right motor to speed -90
5 | wait 5 seconds
6 | set left motor to speed 0
7 | set right motor to speed 0
8 | end while

(A) Line 2, 3, 4, 5
(B) Line 2, 6, 7
(C) Line 5
(D) Line 1, 3, 4
Question (5)

Pulse Width Modulation (PWM) is a method used to reduce the average power
delivered by an electrical signal, by effectively chopping the signal into discrete parts.
In the following diagram that shows the duty cycle of an electrical signal, what will
happen if a digital signal of 75% duty cycle is connected to a light bulb?

(A) The lower the duty cycle, the shorter the light bulb is on, the brighter the
light and it also corresponds to high power.
(B) The lower the duty cycle, the longer the light bulb is on, the dimmer the
light and it also corresponds to low power.
(C) The higher the duty cycle, the shorter the light bulb is on, the dimmer the
Light and it also corresponds to low power.
(D) The higher the duty cycle, the longer the light bulb is on, the brighter the
light and it also corresponds to high power.
Question (6)

Which of the following program flowchart describes the code shown?

(A)
(B)

(C)

(D)
Question (7)

The flowchart below shows the movement of an automatic car, what is the program
trying to achieve?

(A) The automatic car moves in a circular route.


(B) The automatic car moves in a square route.
(C) The automatic car moves forward and backwards.
(D) The automatic car is making a U-turn.
Question (8)

Artificial Intelligence allow a robot to perform complex tasks. Which of the following
statements is/are FALSE of either Artificial Intelligence (AI), Machine Learning (ML) and
Deep Learning (DL)?

i AI aims to build machines which are capable of thinking like humans.


ii AI is a subset of Data Science.
iii AI is a subset of ML which is a subset of DL.
iv ML is the practice of getting machines to make decisions through data.
v Using ML, the robot trains itself by processing millions of images.
vi ML learns from data, actions and experience.
vii DL is the process of using Artificial Neutral Networks to solve complex
problems.
viii DL is a subset of ML.
ix DL uses multiple layers to progressively extract higher-level features
from the raw input.
x One breakthrough in AI includes numerical password entry in door
unlocking or phone unlocking in the smart phone.

(A) Only statement viii is false


(B) Only statement ii, ix are false
(C) Only statement iii, x are false
(D) None of the statements is false
Question (9)

Which of the following statements correctly describe the more stable bot?

Center of Gravity (CG)


Bot A

Center of Gravity (CG)

Bot B

i Bot A is more stable as the CG is higher due to more weight mounted


high up
ii Bot A is more stable as the CG for Bot B is lower due to lower weight
iii Bot B is more stable as the CG for Bot A is higher due to more weight
mounted high up
iv Bot B is more stable as the CG is lower due to lower weight

(A) i and ii
(B) iii and iv
(C) Both are equally stable
(D) Both are equally unstable
Question (10)

The diagram below shows a 2-wheeled motor robot with 2 light sensors. The robot is
required to move forward by following the black line. Which logic will allow the robot
to follow the line?

Left Sensor Right Sensor Robot Action


White White Turn Left
(A) Black White Move Forward
White Black Turn Right
Black Black Stop

Left Sensor Right Sensor Robot Action


White White Stop
(B) Black White Turn Left
White Black Turn Right
Black Black Move Forward
Left Sensor Right Sensor Robot Action
White White Move Forward
(C) Black White Turn Right
White Black Turn Left
Black Black Stop

Left Sensor Right Sensor Robot Action


White White Move Forward
(D) Black White Turn Left
White Black Turn Right
Black Black Stop
Question (11)

What will be the output after the following statements?

X=5
Y=6
X += Y
print(X)

(A) 5
(B) 6
(C) 11
(D) 1
Question (12)

Joan’s Secret Code


Joan will always send her important messages to her friend Luke in secret code and
they are never in plain text. There are mainly 2 ways for her to encode her messages.

Method 1:
She would replace each letter in the message with the letter which comes 4 places
later in the alphabet. For example, “AFTERNOON” will be send as “EJXIVRSSR”.

Method 2:
She would send across her message + key. Then she would replace each letter with
key places later in the alphabet. For example, “AFTERNOON” with Key=2 will be send
as “CHVGTPQQP”.

Using Method 1, what should be the message to be sent for “MORNING”?


(A) OQTPKPI
(B) EJXIVRS
(C) QSVRMRK
(D) CHVGTPQ
Question (13)

Joan’s Secret Code


Joan will always send her important messages to her friend Luke in secret code and
they are never in plain text. There are mainly 2 ways for her to encode her messages.

Method 1:
She would replace each letter in the message with the letter which comes 4 places
later in the alphabet. For example, “AFTERNOON” will be send as “EJXIVRSSR”.

Method 2:
She would send across her message + key. The she would replace each letter with key
places later in the alphabet. For example, “AFTERNOON” with Key = 2 will be send as
“CHVGTPQQP”.

Using Method 2, a message NKRRU with key = 6 is sent. What is the original
message?
(A) TQXX[
(B) HELLO
(C) CHVGT
(D) PIZZA
Question (14)

Pseudocode is an informal language that helps programmers develop algorithms.

 Decisions are expressed using if …Endif or if …else….Endif or if …elif…Endif


 for loops are expressed using for each index in sequence

An algorithm is expressed by the following Pseudocode:

Input A, B and C
if A≥B and A≥C
M=A
elif B≥A and B≥C
M=B
else
M=C
Output M

The following four (A,B,C) are input to the algorithm:


(20, 1, 15), (31, 31, 0), (-10, 1, 10), (5, 9, 9)

How many of the outputs will be odd?


(A) 2
(B) 3
(C) 0
(D) 1
Question (15)

An algorithm is expressed by the following Pseudocode:

Input D
T=0
for each index in D
if D[index] = = ‘A’
add 1 to T
Output T

The following three (D) are input to the algorithm:


(“An Apple A Day”), (‘Make it Happen’), (“A Friend”)

If you add the 3 outputs together, what is the value?


(A) 7
(B) 4
(C) 3
(D) 2
Question 16

Given

(a) What are the arguments in function f1?

(b) What is the output for the following?

(c) What is the output for the following?


Question 17

(a) Create an instance of the above Cat class named A with attribute name=’missy’
and age=3.

(b) B is an object created from Cat class. What is the output for B.sound()?

(c) Give one method in Cat Class.


Answers for HCIC 2021

Question No. Answer


Q1 D
Q2 D
Q3 C
Q4 A
Q5 D
Q6 B
Q7 B
Q8 C
Q9 B
Q10 D
Q11 C
Q12 C
Q13 B
Q14 A
Q15 B
Q16 (a) one
Q16 (a) two
Q16 (b) a: 7 b: 5

Q16 (c) c: 1 d: 1
Q17 (a) A=Cat(“missy”,3)
Q17(b) Meow…
Q17 (c) __init__()
sound()

You might also like