Files
LeetCode-Go/leetcode/0551.Student-Attendance-Record-I/551.Student Attendance Record I_test.go
2021-08-17 17:30:59 +08:00

46 lines
610 B
Go

package leetcode
import (
"fmt"
"testing"
)
type question551 struct {
para551
ans551
}
// para 是参数
type para551 struct {
s string
}
// ans 是答案
type ans551 struct {
ans bool
}
func Test_Problem551(t *testing.T) {
qs := []question551{
{
para551{"PPALLP"},
ans551{true},
},
{
para551{"PPALLL"},
ans551{false},
},
}
fmt.Printf("------------------------Leetcode Problem 551------------------------\n")
for _, q := range qs {
_, p := q.ans551, q.para551
fmt.Printf("【input】:%v 【output】:%v \n", p, checkRecord(p.s))
}
fmt.Printf("\n\n\n")
}