Question: Write Trace Table and draw a flowchart to find and print the largest of N (N can be any number) numbers. Read numbers one by
Write Trace Table and draw a flowchart to find and print the largest of N (N can be any number) numbers. Read numbers one by one. Verify your result by a trace table. (Assume N to be 5 and the following set to be the numbers {1 4 2 6 8 })
Algorithm: Step 1: Input N, Current
Step 2: Max = Current
Step 3: Counter =1
Step 4: While(Counter Repeat steps 4 through 7 Step 5: Counter = Counter + 1 Step 6: Input Next Step 7: If (Next>Max) then Max = Next endif Step 8: Print Max
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
