Smith university of st thomas minnesota 12 example

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: m – List the tasks to be performed – Group them into boxes according to control flow – Separate the boxes with diamonds to switch the flow • When writing C – Set up boxes to hold the executable statements – Each ‘if’ statement produces a diamond • The boolean-expression goes in the diamond – Statement ‘inside’ the ‘if’ is below the diamond • Skipped over if false 04/29/09 R. Smith - University of St Thomas - Minnesota 12 Example • First, let’s do the absolute value example • Next, let’s modify the rectangle example – Accept x,y pairs – Calculate lengths even if x,y in wrong order 04/29/09 R. Smith - University of St Thomas - Minnesota 13 Final Phase of C Program Ass...
View Full Document

Ask a homework question - tutors are online