3 条题解

  • 1
    @ 2026-6-28 11:05:08

    这题很简单,while循环保证AC:

    #include <iostream>
    using namespace std;
    int main(){
    	int n,shuwei;
    	cin >> n;
    	while(n){
    		shuwei = n % 10;
    		n /= 10;
    		cout << shuwei << " ";
    	}
    	return 0;
    }
    
    • 0
      @ 2026-3-18 17:07:42

      #include<bits/stdc++.h> using namespace std; int main(){ int m; cin>>m; while(m!=0){ cout<<m%10<<" "; m=m/10; } return 0; }

      • 0
        @ 2026-3-18 17:07:06

        #include<bits/stdc++.h> using namespace std ; int main ( ) { int m ; cin >> m ; while ( m != 0 ) { cout << m % 10 << " " ; m = m / 10 ; } return 0 ; }

        • 1

        信息

        ID
        3492
        时间
        1000ms
        内存
        256MiB
        难度
        5
        标签
        递交数
        43
        已通过
        18
        上传者