首页 试题详情
单选题

以下程序的输出结果为(       )。
N,s=2,3
Def f(s):
    global n
    n=4
    s=s*n
    return s
Print(f(n),n,s)

A 8 4 8

B 8 4 3

C 8 2 3

D 8 2 8

正确答案:A (备注:此答案有误)

相似试题

  • 单选题

    运行以下Python程序输出结果(      )。For c in abcd:     print(c,end=*)

    答案解析

  • 单选题

    以下程序输出结果(        )。A=[123,312,231]a.sort(key=lambda x:x%100/10)print(a[1])

    答案解析

  • 单选题

    若输入123456,则以下Python程序输出结果(        )。A=input()For i in range(len(a)):    print(a[i])

    答案解析

  • 单选题

    以下程序输出结果(       )。N,s=2,3Def f(s):    global n    n=4    s=s*n    return sPrint(f(n),n,s)

    答案解析

  • 单选题

    以下不能实现在同一行上输出1到5之间所有整数平方Python程序是(         )。

    答案解析

热门题库