Question
Draw flowchart, write pseudocode and Pascal program for the problem of finding the smallest number of 10 numbers.
Answer
Flowchart
Pseudocode Start input number N Min=N Count=1 While Count <10 Input number N if N < Min Min=N endif Count=Count + 1 end while print Min end
Pascal Program
Program fimdsmallest; var N:Integer; Count:integer; Min:integer; begin write('Enter a Number ?'); readln(N); Count:=1; Min:=N; while Count < 10 do begin write('Enter a Number ?'); readln(N); if N < Min then Min:=N; Count:=Count+1; end; write('Minimum Number is :') ; writeln(Min); readln; end.
thank you very much
ReplyDeleteThis is a great demonstration of how flowcharts, pseudocode, and Pascal programming can work together to solve a problem like finding the smallest number in a set of 10! The step-by-step pseudocode aligns perfectly with the Pascal program, making it easier to transition from logic to implementation. If you’re looking for an easy way to create flowcharts for problems like this, you might find Creately flowchart maker helpful. It’s a great way to visualize and refine your approach while adhering to proper flowcharting standards!
ReplyDelete