This is Discussion thread about Teams
Discussion About Teams
solving dcb is just like celebrating birthday at mid night
what is wrong in this…
#include<bits/stdc++.h>
using namespace std;
//typedef long long ll;
int main() {
long long int n,m;
cin>>n>>m;
if(m>n)
cout<<“0”<<" “<<“0”;
else
{
long long int n1 = floor(n/m);
long long int n2 = n - (m-1)(n1);
long long int n3 = n-m+1;
long long int maxi= ((n3-2)(n3-1))/2 + n3-1;
long long int mini = (((n1-2)(n1-1))/2+ n1-1)(m-1) + (n2*(n2-1))/2;
cout<<mini<<” "<<maxi;
}
return 0;
}