WorksheetsCoding grade 8
Total questions: 67
Worksheet time: 34mins
Which function runs once when the Arduino starts?
loop()
setup()
delay()
if
Which function runs repeatedly forever?
setup()
pinMode()
loop()
for
Which function sets a pin as INPUT or OUTPUT?
digitalWrite()
pinMode()
digitalRead()
analogRead()
Which function turns a pin ON or OFF?
digitalRead()
analogWrite()
digitalWrite()
delay()
Which function reads ON or OFF from a pin?
digitalRead()
digitalWrite()
analogRead()
Serial.println()
Which function reads sensor values from 0 to 1023?
digitalRead()
analogRead()
analogWrite()
pinMode()
Which function controls brightness or speed (0–255)?
analogRead()
delay()
analogWrite()
digitalRead()
Which function waits for some time in milliseconds?
for
if
delay()
loop()
Which keyword is used to make a decision?
for
if
setup()
delay()
Which keyword repeats code many times?
if
delay()
for
Serial.begin()
Which function starts the Serial Monitor?
Serial.println()
Serial.begin()
digitalWrite()
analogRead()
Which function prints a message with a new line?
Serial.begin()
Serial.print()
Serial.println()
delay()
Which function is usually written at the top of an Arduino program?
loop()
setup()
for
if
Which function is best for controlling LED brightness?
digitalRead()
analogRead()
analogWrite()
pinMode()
Which function is used before digitalWrite()?
delay()
pinMode()
Serial.println()
for
setup() runs again and again forever.
True
False
loop() runs only once when Arduino starts.
True
False
pinMode() is used to read sensor values.
True
False
digitalWrite() can turn a pin ON or OFF.
True
False
digitalRead() returns HIGH or LOW.
True
False
analogRead() values range from 0 to 1023.
True
False
analogWrite() values range from 0 to 255.
True
False
delay() uses seconds as its unit.
True
False
if is used to repeat code many times.
True
False
for is used for repeating code.
True
False
Serial.begin() starts communication with the Serial Monitor.
True
False
Serial.println() prints without moving to a new line.
True
False
digitalWrite() reads values from a pin.
True
False
analogRead() is used only with digital pins.
True
False
loop() is required in every Arduino program.
True
False
setup() is required in every Arduino program.
True
False
pinMode() can set a pin as OUTPUT.
True
False
delay(1000) waits for 1 second.
True
False
analogWrite() can control motor speed.
True
False
digitalRead() reads only ON or OFF values.
True
False
Serial.println() is used to show messages on the Serial Monitor.
True
False
for is not a function, it is a loop keyword.
True
False
if is used for making decisions in code.
True
False
analogWrite() works with values up to 1023.
True
False
digitalWrite() can be used after setting pinMode().
True
False
INPUT components send ______ to the Arduino.
power
commands
information
light
Which function reads INPUT data?
digitalWrite()
analogWrite()
digitalRead()
delay()
Which function is used to read analog sensors?
digitalRead()
analogRead()
digitalWrite()
Serial.begin()
OUTPUT components ______ commands from Arduino.
send
block
receive
ignore
Which function controls OUTPUT components?
digitalRead()
analogRead()
digitalWrite()
if
Which of the following is an INPUT component?
LED
Buzzer
Push Button
Servo Motor
Which of the following is an OUTPUT component?
LDR
PIR Sensor
Ultrasonic Sensor
LED
Which component is used to measure distance?
PIR Sensor
Ultrasonic Sensor
LDR
Joystick
Which INPUT component detects motion?
LDR
PIR Sensor
Gas Sensor
Potentiometer
Which INPUT component measures light?
IR Sensor
LDR
Joystick
Sound Sensor
Which OUTPUT component makes sound?
LED
Buzzer
Fan
Relay
Which OUTPUT component shows text or numbers?
Relay
Servo Motor
LCD Display
Gas Sensor
Which OUTPUT component rotates to a specific angle?
DC Motor
Stepper Motor
Servo Motor
Fan
Which OUTPUT component can turn high-power devices ON or OFF?
LED
Relay Module
RGB LED
Buzzer
Which component can move in many steps?
Servo Motor
DC Motor
Stepper Motor
Fan
INPUT components send information to Arduino.
True
False
OUTPUT components send data to Arduino.
True
False
digitalRead() is used for INPUT components.
True
False
analogWrite() is used for INPUT components.
True
False
Push Button is an INPUT component.
True
False
LED is an OUTPUT component.
True
False
Joystick is an INPUT component.
True
False
Ultrasonic Sensor is an OUTPUT component.
True
False
Buzzer is an INPUT component.
True
False
PIR Sensor detects motion.
True
False
LCD Display receives commands from Arduino.
True
False
Fan is an OUTPUT component.
True
False
