File: E043_bad.sh

package info (click to toggle)
python-bashate 2.1.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 380 kB
  • sloc: python: 743; sh: 202; makefile: 22
file content (10 lines) | stat: -rw-r--r-- 136 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
count=0
things="0 1 0 0 1"

for i in $things; do
    if [ $i == "1" ]; then
        (( count++ ))
    fi
done

echo "Count is ${count}"