-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.go
58 lines (54 loc) · 1.21 KB
/
main.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
package main
import (
"log"
"os"
problem0 "protohackers/lib/problem-0"
problem1 "protohackers/lib/problem-1"
problem10 "protohackers/lib/problem-10"
problem11 "protohackers/lib/problem-11"
problem2 "protohackers/lib/problem-2"
problem3 "protohackers/lib/problem-3"
problem4 "protohackers/lib/problem-4"
problem5 "protohackers/lib/problem-5"
problem6 "protohackers/lib/problem-6"
problem7 "protohackers/lib/problem-7"
problem8 "protohackers/lib/problem-8"
problem9 "protohackers/lib/problem-9"
)
var problemSelection string
func init() {
problemSelection = os.Getenv("PROBLEM")
if problemSelection == "" {
problemSelection = "problem-0"
}
}
func main() {
switch problemSelection {
case "problem-0":
problem0.Problem()
case "problem-1":
problem1.Problem()
case "problem-2":
problem2.Problem()
case "problem-3":
problem3.Problem()
case "problem-4":
problem4.Problem()
case "problem-5":
problem5.Problem()
case "problem-6":
problem6.Problem()
case "problem-7":
problem7.Problem()
case "problem-8":
problem8.Problem()
case "problem-9":
problem9.Problem()
case "problem-10":
problem10.Problem()
case "problem-11":
problem11.Problem()
default:
log.Fatal("Problem not found")
}
}