4 solutions

  • 0
    @ 2022-1-3 19:56:16

    嗯同余~~(楼下说写题解加深印象)~~

    #include<stdio.h>
    #include<iostream>
    using namespace std;
    typedef long long ll;
    int main()
    {
    	ll a,b,c,ans;
    	while(cin>>a>>b>>c)
    	{
    		ans=((a%c)*(b%c))%c;
    		cout<<ans<<endl;
    	}
    	return 0;
    }
    

    Information

    ID
    278
    Time
    1000ms
    Memory
    256MiB
    Difficulty
    6
    Tags
    # Submissions
    175
    Accepted
    57
    Uploaded By