Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit35c6379

Browse files
refactor 1154
1 parentf65cb47 commit35c6379

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

‎src/main/java/com/fishercoder/solutions/_1154.java

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2,35 +2,6 @@
22

33
importjava.util.Calendar;
44

5-
/**
6-
* 1154. Day of the Year
7-
*
8-
* Given a string date representing a Gregorian calendar date formatted as YYYY-MM-DD, return the day number of the year.
9-
*
10-
* Example 1:
11-
*
12-
* Input: date = "2019-01-09"
13-
* Output: 9
14-
* Explanation: Given date is the 9th day of the year in 2019.
15-
* Example 2:
16-
*
17-
* Input: date = "2019-02-10"
18-
* Output: 41
19-
* Example 3:
20-
*
21-
* Input: date = "2003-03-01"
22-
* Output: 60
23-
* Example 4:
24-
*
25-
* Input: date = "2004-03-01"
26-
* Output: 61
27-
*
28-
* Constraints:
29-
*
30-
* date.length == 10
31-
* date[4] == date[7] == '-', and all other date[i]'s are digits
32-
* date represents a calendar date between Jan 1st, 1900 and Dec 31, 2019.
33-
* */
345
publicclass_1154 {
356
publicstaticclassSolution1 {
367
Calendarcal =Calendar.getInstance();

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp