[Fortran] 纯文本查看 复制代码 program test0504
implicit none
integer year
write(*,*) "Please input the yaer:"
read(*,*) year
if((mod(year,4)==0).or.(mod(year,100)==0.and.mod(year,400)==0)) then
write(*,*) "This year is a leap yaer."
else
write(*,*) "This year is not a leap yaer."
end if
end program test0504 |