Skip to content

Latest commit

 

History

History
22 lines (16 loc) · 243 Bytes

README.md

File metadata and controls

22 lines (16 loc) · 243 Bytes

chs

help to replace judging-code in golang

change

    if a == 0 {
        a = defaultValue
    }
    if s == "" {
        s = defaultStr
    }

to

    a = IntOrDefault(a,defaultValue)
    s = StrOrDefault(s,defaultStr)