C++ | Static Keyword | Question 3
Which of the following is true?
(A) Static methods cannot be overloaded.
(B) Static data members can only be accessed by static methods.
(C) Non-static data members can be accessed by static methods.
(D) Static methods can only access static members (data and methods)
Answer: (D)
Explanation:
Quiz of this Question
Recommended Posts:
- C++ | Static Keyword | Question 5
- C++ | Static Keyword | Question 6
- C++ | Static Keyword | Question 4
- C++ | Static Keyword | Question 2
- C++ | Static Keyword | Question 1
- Static Keyword in C++
- Comparison of static keyword in C++ and Java
- Output of Java Programs | Set 48 (Static keyword)
- Understanding "static" in "public static void main" in Java
- Difference between static and non-static variables in Java
- Difference between static and non-static method in Java
- Internal static variable vs. External static variable with Examples in C
- C++ | const keyword | Question 3
- C++ | const keyword | Question 1
- C++ | friend keyword | Question 1

