MCQOPTIONS
Saved Bookmarks
| 1. |
Which of the following statements is correct about the C#.NET code snippet given below? class Sample { private int i; public Single j; private void DisplayData() { Console.WriteLine(i + " " + j); } public void ShowData() { Console.WriteLine(i + " " + j); } } |
| A. | J cannot be declared as public. |
| B. | DisplayData() cannot be declared as private. |
| C. | DisplayData() cannot access j. |
| D. | There is no error in this class. |
| Answer» E. | |