wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Intro-Arduino

Total questions: 5

Worksheet time: 3mins

Name
Class
Date
1.

Which function in Arduino programs is used to initialize variables and settings before the main loop starts?

a)

void loop()

b)

void begin()

c)

void init()

d)

void setup()

2.

Which of the following steps are needed to print a message to the serial monitor in an Arduino program?

a)

Use Serial.println() to print the message.

b)

Initialize serial communication with Serial.begin()

c)

Ensure the baud rate matches between the program and serial monitor

d)
Print messages directly to the console without any code.
3.

What role does the void loop() function play in an Arduino program?

a)
The void loop() function allows the Arduino to execute code continuously after setup.
b)
The void loop() function is used to define global variables.
c)
The void loop() function is only executed once during the program.
d)
The void loop() function initializes the Arduino hardware.
4.

How do you configure pin 13 as an output in an Arduino sketch?

a)
pinMode(13, HIGH);
b)
digitalWrite(13, OUTPUT);
c)
setPinMode(13, OUTPUT);
d)
pinMode(13, OUTPUT);
5.

How can you turn off the built in LED in 500 ms using digitalWrite?

a)

digitalWrite(13, LOW);

delay(1000);

b)

digitalWrite(13, LOW);

delay(250);

c)

digitalWrite(13, LOW);

delay(500);

d)

digitalWrite(13, HIGH);

delay(500);