Select the correct output of the following C++ program segment, assuming all…

Navodaya Vidyalaya Samiti 2022

Select the correct output of the following C++ program segment, assuming all necessary header files are correctly included.

void main () { char *S = "Inheritance"; S += 6; cout << S << endl; }

  1. A.

    itence

  2. B.

    tance

  3. C.

    Tence

  4. D.

    Inheri

Attempted by 706 students.

Sign up free to check your answer

Sign up free

Explore the full course: Bpsc

Loading lesson…