dr [0] = c.getTime (); line you will get time for SUNDAY because you set it and the date then returns 23.3. Principal is the same for the end of week: On the line. c.set (day, c.getActualMaximum (day)); you set "DAY_OF_WEEK" to SATURDAY and then it will return you date 22.3. //EDIT2: method for calculating start and end of week.
About java.time. The java.time framework is built into Java 8 and later. These classes supplant the troublesome old legacy date-time classes such as java.util.Date, Calendar, & SimpleDateFormat.
Within this calendar, a standard year consists of 365 days with a leap day being introduced to the month of February during a leap year. The months of April, June, September, and November have 30 days, while the rest have 31 days except for February, which has 28 days in a standard year, and 29 in a leap year.
Enter a day of the year or 0 to quit: 10 Jan 10 Enter a day of the year or 0 to quit: 200 Jul 19 Enter a day of the year or 0 to quit: 0 Bye! Share Follow
Vay Tiền Online Chuyển Khoản Ngay.
java day of year