
Functions in C - Worksheet
Authored by V. Charles Prabu
Information Technology (IT)
11th Grade
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is a function in C?
A variable that stores data
A block of code that performs a specific task
A loop that repeats code
A comment in the program
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which keyword is used to define a function in C?
define
function
void
No special keyword is needed
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of the return statement in a function?
To print output
To exit the program
To send a value back to the caller
To define a variable
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a correct function declaration in C?
function add(int a, int b)
int add(int a, int b)
add(int a, int b)
int add(a, b)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the default return type of a function in C if not specified?
void
float
int
char
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is used to pass arguments to a function in C?
return
main()
Function parameters
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the void keyword indicate in a function declaration?
The function returns a value
The function has no name
The function does not return any value
The function has no parameters
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
20 questions
Producción de Contenido
Quiz
•
9th - 12th Grade
17 questions
Latihan Soal Informatika
Quiz
•
8th Grade - University
10 questions
EXCEL
Quiz
•
9th - 12th Grade
10 questions
Programação e Robótica - Recuperação 1
Quiz
•
11th Grade
10 questions
BÀI 18. THỰC HÀNH XÁC ĐỊNH CẤU TRÚC BẢNG VÀ CÁC TRƯỜNG KHÓA
Quiz
•
11th Grade
15 questions
TVL 1
Quiz
•
11th Grade
15 questions
S2 Microsoft Access Database Quiz
Quiz
•
10th Grade - University
13 questions
Parcial 1 Reparación y Soporte- 5to BACO - I Unidad Forma A
Quiz
•
10th Grade - University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
Discover more resources for Information Technology (IT)
20 questions
-AR -ER -IR present tense
Quiz
•
10th - 12th Grade
15 questions
Making Inferences
Quiz
•
7th - 12th Grade
15 questions
Main Idea and Supporting Details.
Quiz
•
4th - 11th Grade
12 questions
Add and Subtract Polynomials
Quiz
•
9th - 12th Grade
7 questions
How James Brown Invented Funk
Interactive video
•
10th Grade - University
15 questions
Atomic Habits: Career Habits
Lesson
•
9th - 12th Grade
16 questions
ACT English - Grammar Practice #2
Quiz
•
11th Grade
20 questions
Banking
Quiz
•
9th - 12th Grade