+ 1

Can this be shorter

*cout<< "If you were born on "; cout<< birth; cout<< "\n Your age at "; cout<< find ; cout<< " will be "; cout<< res;* ^ can I print those in less line ps: all the variables(birth, find, res) are integers

12th Nov 2016, 1:17 PM
Ziyaan Hassan
Ziyaan Hassan - avatar
2 Respuestas
+ 2
cout << "If you were born on " << birth << "\n Your age at " << find << " will be " << res;
12th Nov 2016, 1:27 PM
Aditya kumar pandey
Aditya kumar pandey - avatar
+ 1
nvm this works * cout<< "If you were born on "<<birth ; cout<< "\n Your age at "<<find; cout<< " will be "<<res;*
12th Nov 2016, 1:24 PM
Ziyaan Hassan
Ziyaan Hassan - avatar