1 solutions

  • 0
    @ 2024-7-20 19:41:41

    还来看题解?自己写

    #include<bits/stdc++.h>
    using namespace std;
    double a,b;
    double mod(double a,double b){
    	while(a>=b){
    		a-=b;
    	}
    	return a;
    }
    int main(){
    	cin>>a>>b;
    	cout<<mod(a,b);
    	return 0;
    }
    
    • 1

    Information

    ID
    6870
    Time
    1000ms
    Memory
    128MiB
    Difficulty
    1
    Tags
    # Submissions
    6
    Accepted
    5
    Uploaded By