Computer Science, asked by jeyaseelan76, 10 months ago

write a qb 64 program to check whether a given year is a leap year or not ​

Answers

Answered by mayanksharma789594
4

Explanation:

DIM X, Y, Z, YEAR

INPUT "PLEASE INPUT YEAR"; YEAR

X = YEAR MOD 4

Y = YEAR MOD 100

Z = YEAR MOD 400

IF ((X = 0 AND NOT (Y = 0)) OR Z = 0) THEN

PRINT "THIS IS A LEAP YEAR"; YEAR

ELSE

PRINT "THIS IS NOT LEAP YEAR"; YEAR

END IF

END

Answered by arshali94
3

Answer:

I think so it can be this

Explanation:

If it is divisible by 4 then it is divided by 100 and then 400. If year is divisible by all 3 numbers then that year is a leap year. If the year is divisible by 4 and 100 but not by 400 then it is not a leap year. If the year is divisible by 4 but not by 100, then it is a leap year.

I hope so ...

Similar questions