7 条题解

  • 5
    @ 2023-1-23 15:01:47
    #include<iostream>
    using namespace std;
    int main(){
    	int a,b;
    	cin>>a>>b;
    	cout<<a%b<<" "<<a/b;
    	return 0;
    }
    

    求赞

    • 1
      @ 2023-11-7 17:39:33
      #include <stack>
      #include <iostream>
      #include <iomanip>
      #include <string.h>
      #include <algorithm>
      using namespace std;
      int main() 
      {
          int n,m,a,b,c;
          cin>>n>>m;
          a=n/m;
          c=a*m;
          b=n-c;
          cout<<b<<" "<<a;
      }
      
      • 0
        @ 2024-3-30 17:28:34
        #include <iostream> 
        using namespace std;
        int main()
        {
        	int n,m,c,d;	
        	cin >>n>>m;
        	c = n % m;	
        	d = (n - c) / m;
        	cout << c << ' ' << d << endl;
        }
        
        • 0
          @ 2022-11-14 17:55:20
          #include <iostream>
          using namespace std;int main(){int n,m,a,b,c;cin>>n>>m;a=n/m;c=a*m;b=n-c;cout<<b<<" "<<a;}
          
          哈哈哈哈哈哈
          • 0
            @ 2022-8-2 9:25:07

            先用数学的方式理解

            #include <stack>
            #include <iostream>
            #include <iomanip>
            #include <string.h>
            #include <algorithm>
            using namespace std;
            int main() 
            {
                int n,m,a,b,c;
                cin>>n>>m;
                a=n/m;
                c=a*m;
                b=n-c;
                cout<<b<<" "<<a;
            }
            
            
            • @ 2022-11-14 18:12:51

              @ ?

            • @ 2024-11-2 20:12:49

              @ ??????????????????????????????????? @ ???????????????????????????????????

          • -7
            @ 2022-7-1 21:03:14

            #include <stdio.h>

            #include

            using namespace std;

            int main()

            {

            int a,b;
            
            cin>> a >> b ;
            
            cout<< a % b << " " << (a - a % b) /b;
            

            }

            • -12
              @ 2022-1-8 10:54:52
              #include <stack>
              #include <iostream>
              #include <iomanip>
              #include <string.h>
              #include <algorithm>
              using namespace std;
              
              int main() {
              int n,m,a,b,c;
              cin>>n>>m;
              a=n/m;
              c=a*m;
              b=n-c;
              cout<<b<<" "<<a;
              }
              
              • 1

              信息

              ID
              811
              时间
              1000ms
              内存
              128MiB
              难度
              5
              标签
              递交数
              1588
              已通过
              594
              上传者