What will be the output of the following code?
#include <iostream>
#include <string>
using namespace std;
int main() {
string str = "Hello";
str.pop_back();
cout << str;
return 0;
}
Hello
Hell
ello
Helo
This question is part of this quiz :
Quiz on C++ Strings