Week 5 上周知识点回顾

Week 5 上周知识点回顾

12th Grade

10 Qs

quiz-placeholder

Similar activities

自定義函數

自定義函數

10th Grade - University

5 Qs

Week 5 上周知识点回顾

Week 5 上周知识点回顾

Assessment

Quiz

Information Technology (IT)

12th Grade

Medium

Created by

Nila Zhang

Used 1+ times

FREE Resource

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Python中的'if'语句需要什么?

一个函数调用

一个循环

一个条件表达式

一个返回值

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

双分支if/else语句的语法是什么?

if condition then body1 else body2

if condition body1 else body2

if condition: body1; else: body2

if condition: body1 else: body2

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

当迭代次数未知时,通常使用哪种循环?

无限循环

While 循环

For 循环

嵌套循环

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

在循环中,'continue'语句的作用是什么?

结束循环

退出程序

重新开始循环

跳过当前迭代

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

什么关键字用于从函数返回一个值?

return

output

yield

send

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

如果一个函数没有返回语句,会发生什么?

它将返回零

它将返回 None

它将导致错误

它将返回一个空字符串

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

循环中 'break' 语句的目的是什么?

暂停循环

继续到下一个迭代

终止循环

跳过当前迭代

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?