• Robert Bradshaw's avatar
    Added for i from ... ['by' step] syntax. · 33b0863c
    Robert Bradshaw authored
    E.g.
    
    for i from 0 <= i < 10 by 2:
        print i
    
    0
    2
    4
    6
    8
    
    Old for-from loops remain exactly the same (using the ++ or --). If step is specified, the increment operator will be += step or -= step, depending on the orientation of the inequalities (as before).
    
    NOTE: 'by' is now a keyword
    33b0863c
Parsing.py 57.1 KB