原文:用JS写,根据用户输入的年月份判断是这年的第几天

console.log 输入年份: let year readline.question console.log 输入一个月份 let month readline.question console.log 输入天数 let day readline.question if year gt amp amp year lt if month gt amp amp month lt if day g ...

2018-05-19 12:52 0 1035 推荐指数:

查看详情

Python输入年月日,判断这一天是这一第几天

1. 【问题描述】 输入某年某月某日,判断这一天是这一第几天?程序分析:以3月5日为例,应该先把前两个月的加起来,然后再加上5天即本年的第几天。特殊情况:闰年且输入月份大于3时需考虑多加一天。 提示:(1) 闰年的2月有29天,平年的2月有28天 ...

Sat Dec 01 01:55:00 CST 2018 0 1825
 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM