Home / CSE MCQs / C++ - MCQs :: Discussion

Discussion :: C++ - MCQs

  1. What is the output of this program?

    #include < iostream >

    using namespace std;

    #define SquareOf(x) x * x

    int main()

    {

    int x;

    cout << SquareOf(x + 4);

    return 0;

    }



  2. A.
    16
    B.
    64
    C.
    compile time error
    D.
    none of the mentioned

    View Answer

    Workspace

    Answer : Option D

    Explanation :

    In this program, as we haven't initiailzed the variable x, we will get a output of ending digit of 4.


Be The First To Comment