How do i input an if else statement inside an already existing if else statement?
FreddyGIraheta 0 Newbie Poster
Recommended Answers
Jump to PostAre you asking about something like this?
if(something) { if(somethingelse) { //... } else { //... ) } else { if(somethingelse) { //... } else { //... } }
Jump to Postif(true) do_this; else if(true) do_this; else if(true) do_this; else if(true) do_this; else if(true) do_this;
This is called a decesion tree, and only one if statement will execute out of the whole bunch. When one of the if statements does execute, then control drops out to …
All 5 Replies
Elixir42 0 Junior Poster in Training
NathanOliver 429 Veteran Poster Featured Poster
Elixir42 0 Junior Poster in Training
FreddyGIraheta 0 Newbie Poster
MandrewP 60 Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.