General area when it fits no where else

Moderator: Mmiscool

User avatar
By Alberto_2
#73881 Code: (that doesn't work)

msg = ""
cnt = 1
do
cnt = cnt + 1
delay 500
loop while len(msg) < 38 or cnt < 22
If cnt > 21 then goto [repet]

Code: (that work)

msg = ""
cnt = 1
do
cnt = cnt + 1
If cnt > 21 then goto [repet]
delay 500
loop while len(msg) < 38


Question 1: Why the logic "or" stops the loop and does prevent string "msg" to load ?
Question 2: Is it safe to exit the "do/loop while" with a goto instruction?

Thank you for the attention.


Edited: Missing "THEN" was a typo! The question remain. Interested in question 2

Alberto
Last edited by Alberto_2 on Sun Feb 11, 2018 3:44 pm, edited 2 times in total.