Computer Science, asked by Alia20061, 9 months ago

Int findtotal(int a,int b){
if(b == 1)
return a;
if(a==b)
return 1;
int p = a-b;
return 1+ findtotal(max(p,b),min(p,b));
}
int main(){
int a=5;
int b=7;
int c=3;
int d=4;
cin>>a>>b>>c>>d;
int total =0;
//two for loops to get all possible sizes of box .then count
for(int i=a;i<=b;i++){
for( int j=c;j<=d;j++){
total+= findtotal(max(i,j),min(i,j););
}
}
cout<

Answers

Answered by TheDiffrensive
1

Here is your Answer mate ❤️

..

...

..

Similar questions