Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
horse aand goat working
#include <iostream> using namespace std; int main() { int t; cin>>t; while(t--){ unsigned int h,g,l,N,h1=0,g1=0,min=0,max=0; cin>>g>>h>>N; h1=h*2; if(g>h1) { g1=g-h1; } min=h*4+g1*4; max=h*4+g*4; cout<<max<<" "<<min<<endl; if((N<=max && N>=min) && N%4==0 ) { cout<<"yes"; } else cout<<"no"; if(t>0) { cout<<endl; } } cout<<endl; return 0; }
run
|
edit
|
history
|
help
0
Please
log in
to post a comment.
string
stack
Lockable static queue
vector fr
1068 - Investigation
string match2
Test 8(2010)
snake logic complete c++
Elevator 2
Right view of a tree
Please log in to post a comment.