Home / C# Programming / Datatypes :: Discussion

Discussion :: Datatypes

  1. Which of the following is the correct ways to set a value 3.14 in a variable pi such that it cannot be modified?

  2. A.
    float pi = 3.14F;
    B.
    #define pi 3.14F;
    C.
    const float pi = 3.14F;
    D.
    const float pi; pi = 3.14F;
    E.
    pi = 3.14F;

    View Answer

    Workspace

    Answer : Option C

    Explanation :

    No answer description available for this question.


Be The First To Comment