Warmup - Python - Machine Learning

Warmup - Python - Machine Learning

University

30 Qs

quiz-placeholder

Similar activities

Quiz on Lesson 1 CSU3200

Quiz on Lesson 1 CSU3200

University

33 Qs

Quiz tentang Data dan Informasi 9

Quiz tentang Data dan Informasi 9

9th Grade - University

25 Qs

SAS 1 Informatika 8

SAS 1 Informatika 8

8th Grade - University

25 Qs

Kelas 9-Refreshing Berpikir Komputasional

Kelas 9-Refreshing Berpikir Komputasional

9th Grade - University

25 Qs

Mobile Teknology & IoT 1

Mobile Teknology & IoT 1

University

25 Qs

Preliminary Examination _ IT Era

Preliminary Examination _ IT Era

University

25 Qs

UTS INFORMATIKA KELAS E

UTS INFORMATIKA KELAS E

8th Grade - University

25 Qs

Sumatif bab 6 dan 7

Sumatif bab 6 dan 7

8th Grade - University

25 Qs

Warmup - Python - Machine Learning

Warmup - Python - Machine Learning

Assessment

Quiz

Information Technology (IT)

University

Practice Problem

Medium

Created by

Trịnh Tú

Used 2+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

30 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct file extension for Python files?

.pyth
.pt
.py
.pyt

Answer explanation

Python files have the extension .py

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which keyword is used to define a function in Python?

func
define
def
function

Answer explanation

Functions in Python are defined using 'def'

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of these data types is immutable in Python?

List
Tuple
Dictionary
Set

Answer explanation

Tuples are immutable, unlike lists or dictionaries

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you insert comments in Python code?

/* comment */
<!-- comment -->
// comment
# comment

Answer explanation

Comments in Python start with #

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the len() function do in Python?

Returns the type of a variable
Returns the number of items in an object
Returns the memory address
None of the above

Answer explanation

len() returns the number of elements in a collection

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is used to handle exceptions in Python?

try-except
do-catch
handle-except
error-catch

Answer explanation

Python uses try-except for exception handling

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method is used to add an item to a list?

add()
append()
insert()
push()

Answer explanation

The append() method adds an item at the end of the list

Create a free account and access millions of resources

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?