C++
-
If a, b and c are variable of type int. without changing the types write a program to display C = 1.5 if a is 3 and b is 2
-
If a, b and c are variable of type int. without changing the types write a program to display C = 1.5 if a is 3 and b is 2
We don't do your homework. :thumbsdown:
The difficult we do right away... ...the impossible takes slightly longer.
-
We don't do your homework. :thumbsdown:
The difficult we do right away... ...the impossible takes slightly longer.
sorry...didnt mean to be rude its just a test i saw somewhere and i dont know how to do it...all i want is for you guys to tell me what its under or explain what im supposed to do not to write the program. I'm a beginner in C++...Pls guys
-
If a, b and c are variable of type int. without changing the types write a program to display C = 1.5 if a is 3 and b is 2
-
If a, b and c are variable of type int. without changing the types write a program to display C = 1.5 if a is 3 and b is 2
For a precision of one-tenth:
printf("C = %d.%d\n", a / b, abs(((10 * a) / b) % 10));
-
If a, b and c are variable of type int. without changing the types write a program to display C = 1.5 if a is 3 and b is 2
I guess the question is hinting type casting[^].
«_Superman_» _I love work. It gives me something to do between weekends.
_Microsoft MVP (Visual C++) (October 2009 - September 2013)