
'---------
'ITERATION
'=========

  dim a,b,c,d,i as long
  dim s as string = "QWERTY"


  'checksum example

  b=0
  for i=1 to len(s)
    b+=asc(s,i)
  next

  b=0
  for i=1 to len(s) step 1
    b+=asc(s,i)
  next

  b=0
  for i=len(s) to 1 step -1
    b+=asc(s,i)
  next


'-----------------
'SYNTAX VARIATIONS
'=================


  b=0
  for i=1 to len(s) step 1 {
    a=asc(s,i)
    b+=a
  }

  'b=0
  'for i=1,len(s), 1 {
  '  a=asc(s,i)
  '  b+=a
  '}

  b=0
  for (i=1, i<=len(s), i++) {
    a=asc(s,i)
    b+=a
  }

  b=0
  for (i=1; i<=len(s); i++) {
    a=asc(s,i)
    b+=a
  }

  b=0
  for (i=1, i<=len(s), i++) {
    a=asc(s,i)
    b+=a
  }


 def qu "'"
 print "Checksum for " qu s qu " = " b




  

 