1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

俺も次のプレミアムフライデーがいつか調べるの作った

Last updated at Posted at 2017-03-08

みんな作っているのを見て、あれば安心かと思い自分用の物を作った。

main.go
package main 

import ( 
	"fmt" 
	"time" 
) 

func main() {
	pf := time.Now()
	 
	for { 
		if pf.Day() != 13 || pf.Weekday() != time.Friday { 
			pf = pf.Add(24 * time.Hour)
			continue 
		}
		break
	} 
	fmt.Printf("気をつけろ!次の出動日は %s だぜ!\n", pf.Format("2006年01月02日")) 
}

これで安心!
みんなと違っても気にしない。

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?