x=input("x=")x=2*float(x)print(x)输入x=23b输出结果是
A: 46
B: 0
C: 错误
D: 4
A: 46
B: 0
C: 错误
D: 4
举一反三
- x=input("x=")x=2*float(x)print(x)输入x=23b输出结果是 A: 46 B: 0 C: 错误 D: 4
- x=input(x=)x=2*float(x)print(x)输入x=23b输出结果是
- 程序执行时输入12和34,结果如下所示,那么print()函数正确的调用形式是( )请输入x:12请输入y:34x= 12 y= 34 A: print("x=",x ; "y=",y) B: print("x=",x,"y=",y) C: print(x,y) D: print(x=,x,y=,y)
- int x = 3,y = 4;以下哪条输出语句正确? A: Console.WriteLine("x={x},y={y}", x,y); B: Console.WriteLine("x={x},y={y}"); C: Console.WriteLine("x={0},y={1}", x,y); D: Console.WriteLine("x={1},y={2}", x,y);
- 对若干个正数求和,输入“ok”结束,下面正确的代码是( )。知识点:while循环。 A: s = 0x = input()while x!="ok": s += int(x) print(s) B: s = 0while True: x = input() if x=="ok": break s += int(x) print(s) C: s = 0x = input()while x!="ok": s += int(x) x = input()print(s) D: s = 0while x!="ok": x = input() s += int(x) print(s)