While loop will work when the condition is true. If the condition is true for infinite times then the loop will run for infinite times.
open a editor and write the below mentioned code,
#!/bin/bash
a=10
while [[ $a -lt 20 ]]
do
echo "$a"
a=$((a + 1))
done
sh while.sh