Examlex

Solved

What Is the Output of the Following Code Fragment

question 35

Multiple Choice

What is the output of the following code fragment?
Int v1=2, v2=-1, *p1, *p2;
P1 = & v1;
P2= & v2;
P2=p1;
Cout << *p2 << endl;


Definitions:

Inflexible Shoes

Footwear that lacks flexibility, potentially leading to discomfort or reduced mobility during wear.

High-top Shoes

Footwear that extends slightly over the wearer's ankle, often used for added support.

Cultural Groups

Refers to a collection of people who share common values, traditions, or behaviors based on ethnicity, religion, language, or national origin.

Solid Food

Food that has been pureed or is in firm pieces, introduced to infants typically around 6 months of age to complement breast milk or formula feeding.

Related Questions