What is the output of the following code?
char ch = 'G';
cout << tolower(ch) << endl;
Question 8 options:
A) the integer value of 'G'
B) G
C) g
D) the integer value of 'g'
I tried running it as this.
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
The correct answer is D) - the output of the following code is the integer value of 'g', i.e. 103. And remember, that function should return a value, so add "return 0;" to your main() function.
Comments
Leave a comment