Download presentation
Presentation is loading. Please wait.
Published byAubrey Trotter Modified over 9 years ago
1
Nested if-else Statements
2
Should be indented to make the logic clear. Nested statement executed only when the branch it is in is executed. For example, the statement if (x == 5) { y = 20; } else { if (x > 5) { y = 10; } else { y = 0; } } evaluates the nested if-else only when x is not equal to 5.
3
Flowchart Symbols decision statements of work
4
Flow Chart Basics Rectangles represent statements of work. For example: print() Diamonds (decision symbol) contain conditions flow line
5
Flow Chart Basics Sequence structure Connector symbol Triangle boxes represent statements such as x=30; int a; System.out.print(“x”); x=20;
6
Flowchart
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.