A

Admin • 833K Points
Coach

Q. Which of the following is the correct way of declaring a function as constant?

  • (A) const int ShowData(void) { /* statements */ }
  • (B) int const ShowData(void) { /* statements */ }
  • (C) int ShowData(void) const { /* statements */ }
  • (D) Both A and B
  • Correct Answer - Option(C)
  • Views: 22
  • Filed under category C++
  • Hashtags:

No solution found for this question.
Add Solution and get +2 points.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.