OILS / spec / ysh-unicode.test.sh View on Github | oilshell.org

20 lines, 9 significant
1
2#### ${#s} and len(s)
3
4source $REPO_ROOT/spec/testdata/unicode.sh
5
6# bash agrees
7echo "farmer scalars =" ${#farmer}
8
9echo "facepalm scalars =" ${#facepalm}
10
11echo "farmer len =" $[len(farmer)]
12
13echo "facepalm len =" $[len(facepalm)]
14
15## STDOUT:
16farmer scalars = 4
17facepalm scalars = 5
18farmer len = 15
19facepalm len = 17
20## END