OOPS Concepts - Programming

Q1:

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

ANS:C - int ShowData(void) const { /* statements */ }

No answer description is available. Let's discuss.