cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
Beginners
type of error in goto
type of error in goto
Sep 27, 2013 at 4:35pm UTC
Dknight
(18)
Hello,
what type of error is this:-
1
2
3
4
5
6
7
8
9
10
11
main() {
goto
last;
char
ch=
'a'
; : : : last: : : : }
Sep 27, 2013 at 4:42pm UTC
closed account (
o3hC5Di1
)
Hi there,
I'm afraid I'm not following. Which error are you getting?
Are you sure you want to be using goto - it is generally considered as not the best choice for flow control.
Please be a little more specific and we'll be happy to help you along.
All the best,
NwN
Sep 27, 2013 at 4:43pm UTC
a k n
(325)
Line 1 : syntax error
line 2 : semantic error.
You can't jump between a variable declaration.
Some more syntax error due to the colons.
Sep 27, 2013 at 6:52pm UTC
Dknight
(18)
thank you amhndu:)
Topic archived. No new replies allowed.