View Full Version : pascal goto command
cadaver
03-01-2006, 07:53 PM
how can i use goto in pascal program to go to a specific line
for ex.
we have 3 lined program. in line 3 i want to go to line 2
please give me detailed instruction
thnxs
From what little PASCAL I remember, I don't think this is possible. Is there a reason you can't use labels?
cadaver
03-01-2006, 11:27 PM
can you show me an example of label-goto usage. please.
(* Some code *)
LABELONE:
(* more code *)
GOTO LABELONE;
Actually, from googling around, Turbo Pascal seems to support using line numbers in a GOTO statement (E.G. GOTO 3;). However, this isn't a universal extension.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.