+ 2

Tell me the output of this code.

#include <iostream> using namespace std; void printNumber(int x) { cout << "Prints an integer: " << x << endl; } void printNumber(float x) { cout << "Prints a float: " << x << endl; } int main() { int a = 16; float b = 54.541; printNumber(a); printNumber(b); }

19th May 2017, 2:41 AM
Pranshul Varshney
Pranshul Varshney - avatar
2 Answers
+ 4
Prints an integer: 16 Prints a float: 54.541
19th May 2017, 2:56 AM
trevor villanueva
trevor villanueva - avatar
0
That's simple It just take a as integer and prints it value and b as float and prints its value
27th Oct 2017, 3:20 PM
#RahulVerma
#RahulVerma - avatar