Total Lines | 11 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | package is |
||
2 | |||
3 | // StringInList returns true if one of the elements of the list is equal to the string. |
||
4 | func StringInList(s string, list []string) bool { |
||
5 | for _, ls := range list { |
||
6 | if ls == s { |
||
7 | return true |
||
8 | } |
||
9 | } |
||
10 | |||
11 | return false |
||
12 | } |
||
13 |