Functions in C

Functions in C

12th Grade

15 Qs

quiz-placeholder

Similar activities

C++ programming

C++ programming

7th - 12th Grade

20 Qs

Kuizi 15 - Web

Kuizi 15 - Web

10th Grade - University

15 Qs

J277 - 2.2 - Functions in Python

J277 - 2.2 - Functions in Python

10th Grade - University

10 Qs

functions arguments reference coding

functions arguments reference coding

7th - 12th Grade

11 Qs

Python: Functions and Parameters

Python: Functions and Parameters

9th - 12th Grade

10 Qs

Excel Calculations

Excel Calculations

10th - 12th Grade

20 Qs

Python Basics

Python Basics

12th Grade

20 Qs

Objective 3.3: Apply advanced date and time functions

Objective 3.3: Apply advanced date and time functions

9th - 12th Grade

10 Qs

Functions in C

Functions in C

Assessment

Quiz

Computers

12th Grade

Medium

Created by

Michael Kona

Used 2+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of return type in functions?

To control the loop iterations

To confuse the programmer

To specify the data type of the value that the function will return

To determine the function name

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Explain the role of return statement in functions.

The return statement specifies the value that the function should return when called.

The return statement is optional in functions

The return statement ends the function execution abruptly

The return statement is used to print output to the console

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What are formal arguments in functions?

Variables declared inside the function

Output values returned by the function

Comments within the function

Input parameters specified in the function definition

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Describe actual arguments in functions.

Actual arguments in functions are the values passed to the function when it is called.

Actual arguments in functions are only used in loops

Actual arguments in functions are optional

Actual arguments in functions are the values returned by the function

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How is a function defined in C?

Return_Type function_name(Parameters) { // Function body }

ReturnType function_name(Parameters) // Function body

ReturnType function_name { // Function body }

ReturnType function_name(Parameters) { // Function body }

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax for function calling statement in C?

myFunction(arg1, arg2,);

myFunction(arg1 arg2);

myFunction(arg1, arg2);

myFunction(arg1, arg2)

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Explain call by value in functions.

Changes made to the parameter inside the function affect the original value outside the function.

Call by value allows for direct manipulation of the original argument.

When a function is called, the actual value of the argument is passed to the function. Any changes made to the parameter inside the function do not affect the original value outside the function.

When a function is called, the reference to the argument is passed to the function.

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?