若输入“1298”,以下程序的输出结果为。#include<stdio.h>voidmain{intn1,n2;scanf(%d,&n2);while(n2!=0){n1=n2%10;n2=n2/10;printf(%d,n1);}}()
A: 1298
B: 8921
C: 2189
D: 2198
A: 1298
B: 8921
C: 2189
D: 2198
举一反三
- 下面N×N的笛卡尔积的子集中,哪些可以构成函数? A: {(n1,n2) | n1,n2∈N and n1+n2 <10} B: {(n1,n2) | n1,n2∈N and n2 = n1^2} C: {(n1,n2) | n1,n2∈N and n1 = n2^2} D: {(n1,n2) | n1,n2∈N and n2为小于n1的素数个数}
- 以下程序运行后从键盘上输人1298,则输出结果为: int main(void) { int n1, n2; scanf ("%d", &n2); while (n2 != 0) { n1=n2 % 10; n2=n2/10; printf("%d", n1); } return 0; } A: 1298 B: 8921 C: 2198 D: 9821
- 设n=n1n2,(n1,n2)=1,n1≥1,n2≥1,则φ(n)=φ(n1)φ(n2).若n=n1n2,n1≥1,n2≥1,则φ(n)=φ(n1)φ(n2)?
- 9.以下程序段运行时,如果从键盘输入1298再回车,则输出结果为int n1, n2;scanf("%d", &n2);while (n2 != 0){ n1 = n2 % 10; n2 = n2 / 10; printf("%d", n1);} A: 1298 B: 1 C: 9 D: 8921
- 设有以下程序: main( ) { int n1,n2; scanf("%d",&n2); while(n2!=0) { n1=n2%10; n2=n2/10; printf("%d",n1); } } 程序运行时,如果从键盘上输入1298;则输出结果为__________________ A: 1298 B: 8 C: 89 D: 8921