Solved

Can the Method LastDayOfMonth Be Changed to Be a Static

Question 62

Multiple Choice

Can the method lastDayOfMonth be changed to be a static method by just changing the header to the following?
private static int lastDayOfMonth()


A) No.It could no longer access the month instance variable.
B) No.A class cannot have both static and non-static methods.
C) Yes.No other change is necessary.
D) Yes, but it must be changed to public as well.

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions

Unlock this Answer For Free Now!

View this answer and more for free by performing one of the following actions

qr-code

Scan the QR code to install the App and get 2 free unlocks

upload documents

Unlock quizzes for free by uploading documents