Hello Huy,
the closest to that loop would be:
DO 10 TIMES.
WRITE: / sy-tabix ', '.
ENDDO.
WRITE: / 'Exit the do loop statement".
Also see https://help.sap.com/saphelp_nw04s/helpdata/en/fc/eb3564358411d1829f0000e829fbfe/content.htm
Best regards,
Frank