Demo entry 6624261

sum of 1 to 100

   

Submitted by wtc on Jun 14, 2017 at 20:03
Language: AutoIt. Code size: 116 Bytes.

# the sum of 1 to 100
sum=0
for((i=1;i<=100;i++));
do
sum=$((sum+i))
done
echo -n "sum of 1 to 100 is: "
echo $sum 

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).