Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

C++ Institute CPP Exam - Topic 8 Question 124 Discussion

Actual exam question for C++ Institute's CPP exam
Question #: 124
Topic #: 8
[All CPP Questions]

What will happen when you attempt to compile and run the code below, assuming that you enter the following sequence: 64 100?

#include

#include

#include

#include

using namespace std;

int main ()

{

string s;

getline(cin, s);

stringstream input(s);

stringstream output;

for( ; !input.fail() ; )

{

int i;

input>>hex>>i;

output<

}

cout<

return 0;

}

What will be the result assuming that user will enter following sequence: 64 100:

Show Suggested Answer Hide Answer
Suggested Answer: C

Contribute your Thoughts:

0/2000 characters

Currently there are no comments in this discussion, be the first to comment!


Save Cancel