Scroll to see replies
Spoiler
static boolean isLeapYear (int year){
if (...)
return ...;
else
return ...;
}
and then in main, after receiving the year from the user you could have something like:public static void main (String[] args) {
if (isLeapYear(year))
...
else
...
}
Also, I'm not sure whether it's pastebin, but the whitespace seems very off and it's making things hard to follow.static boolean isLeapYear (int year){
if (...)
return ...;
else
return ...;
}
and then in main, after receiving the year from the user you could have something like:public static void main (String[] args) {
if (isLeapYear(year))
...
else
...
}
Also, I'm not sure whether it's pastebin, but the whitespace seems very off and it's making things hard to follow.Last reply 1 minute ago
Official University of Edinburgh Applicant Thread for 2024Last reply 1 minute ago
Anyone else get an offer for a Rolls Royce degree apprenticeship in Derby (2024)?Last reply 1 minute ago
Official London School of Economics and Political Science 2024 Applicant ThreadLast reply 3 minutes ago
Official University College London Applicant Thread for 2024Posted 4 minutes ago
Lloyds of London Work Experience Year 12 2024Last reply 6 minutes ago
Best university to study Film studies/production?Last reply 7 minutes ago
lloyds bank 2024 apprenticeshipLast reply 8 minutes ago
Official UCL Offer Holders Thread for 2024 entryLast reply 11 minutes ago
Which of these A-Level combinations would be the best to study a law degree?12
Posted 11 minutes ago
Sciences Po Masters in Economics | 2024Posted 12 minutes ago
LSE Financial Maths & Statistics - No related work experience... a problem?Last reply 12 minutes ago
Can I change college after 1 year of BTEC Level 3 Extended Diploma in Applied scienceLast reply 14 minutes ago
Why is the political left now censorious and authoritarian??Last reply 15 minutes ago
LSE anthropology and law 2024Last reply 1 month ago
Free website hosting providers with no strings attached?Posted 3 months ago
iDEA silver citizen badge three. Milkshake shack coding problem.Last reply 4 months ago
How do you practice programming java for beginners?Last reply 8 months ago
hows the employment market for tech work in the UK?Last reply 1 month ago
Free website hosting providers with no strings attached?Posted 3 months ago
iDEA silver citizen badge three. Milkshake shack coding problem.Last reply 4 months ago
How do you practice programming java for beginners?Last reply 8 months ago
hows the employment market for tech work in the UK?