do-while vs. goto?
#1

Hey, this has been bothering me for quite some time now...
Is there any difference between using a goto jump or a do-while loop? For example:
pawn Код:
RANDOMIZATION:
randomSongPick = random(sizeof(aPlayList));
if(aCurrentlyPlaying[playerid] == aPlayList[randomSongPick][0][0]) goto RANDOMIZATION;
And:
pawn Код:
do randomSongPick = random(sizeof(aPlayList));
while(aCurrentlyPlaying[playerid] == aPlayList[randomSongPick][0][0]);
Reply


Messages In This Thread
do-while vs. goto? - by [XST]O_x - 12.04.2013, 19:24
Re: do-while vs. goto? - by Bakr - 12.04.2013, 19:44
Re: do-while vs. goto? - by [XST]O_x - 12.04.2013, 19:49
Re: do-while vs. goto? - by Bakr - 12.04.2013, 20:03
Re: do-while vs. goto? - by [XST]O_x - 12.04.2013, 20:15
Re: do-while vs. goto? - by Bakr - 12.04.2013, 20:26
Re: do-while vs. goto? - by AndreT - 12.04.2013, 20:35
Re: do-while vs. goto? - by [XST]O_x - 12.04.2013, 20:48
Re: do-while vs. goto? - by AndreT - 12.04.2013, 21:05
Re: do-while vs. goto? - by [XST]O_x - 12.04.2013, 21:12

Forum Jump:


Users browsing this thread: 3 Guest(s)