PYTHON PROGRAMMING Q4 FUNCTIONS

PYTHON PROGRAMMING Q4 FUNCTIONS

University

20 Qs

quiz-placeholder

Similar activities

Python Functions and File Operations Quiz cyber 2025

Python Functions and File Operations Quiz cyber 2025

University

18 Qs

Kuizi 15 - Web

Kuizi 15 - Web

10th Grade - University

15 Qs

Java Quiz 1

Java Quiz 1

University

20 Qs

Python: Chapter 5 - True or False

Python: Chapter 5 - True or False

10th Grade - University

15 Qs

PBO Inheritance Episode 2

PBO Inheritance Episode 2

University

18 Qs

300 Quiz03

300 Quiz03

University

18 Qs

Geeks for Geeks PCCOER Info Session CP Quiz

Geeks for Geeks PCCOER Info Session CP Quiz

University

20 Qs

Introduction to Java

Introduction to Java

University

25 Qs

PYTHON PROGRAMMING Q4 FUNCTIONS

PYTHON PROGRAMMING Q4 FUNCTIONS

Assessment

Quiz

Computers

University

Medium

Created by

Darwin Vargas

Used 4+ times

FREE Resource

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What keyword is used to define a function in Python?

  • A. func

  • B. def

  • C. function

  • D. define

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What will be the output of the following code?

  • A. Hello, World!

  • B. hello, world!

  • C. None

  • D. Error

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you pass multiple arguments to a Python function?

  • A. Separate them with commas

  • B. Separate them with semicolons

  • C. Pass them as a list

  • D. Pass them as a dictionary

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What will be the output of the following code?

  • A. 2

  • B. 3

  • C. 5

  • D. 23

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the default return value of a function that doesn’t specify a return value?

  • A. 0

  • B. None

  • C. False

  • D. ''

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you specify default values for function arguments in Python?

  • A. Using the default keyword

  • B. Using the set keyword

  • C. Assigning a value in the function definition

  • D. Assigning a value in the function call

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What will be the output of the following code?

  • A. Hello,

  • B. Hello, None

  • C. Hello, Guest

  • D. Error

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?