Skip to content

Commit

Permalink
Improve output format.
Browse files Browse the repository at this point in the history
  • Loading branch information
haruki-sugarsun committed May 1, 2022
1 parent e6d962d commit 6379884
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion go_ldenweek.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ func isHolidayOrWeekend(day time.Time, holiday_instances []time.Time) bool {
return false
}

func formatDay(day time.Time) string {
return day.Format("2006/1/2")
}

func main() {
// Flag interpretation and Setup.
target_year_flag := flag.Int("year", -1, "Target year of the Christian Era.")
Expand Down Expand Up @@ -133,5 +137,5 @@ func main() {
return cursor
})()

fmt.Printf("Go-ldenweek is %s ~ %s\n", start, end)
fmt.Printf("Go-ldenweek is %s ~ %s\n", formatDay(start), formatDay(end))
}

0 comments on commit 6379884

Please sign in to comment.