answersLogoWhite

0


Best Answer

It's a bit difficult to show a flowchart using nothing but words, but here goes:

start

let list[] be 100 random values

let best be value of list[0]

let index be 1

repeat

is value of list[index] less than best?

YES: let best be value of list[index] {continue}

NO: {continue}

increment index

is index less than 100?

YES: {go to repeat}

NO: {continue}

print value of best

end

Previous answer:

start test number =100 count = count +1 list number =< test number if true testnumber = list number count = 100 goto end else start end

The previous answer assumes 100 to be largest number in the list. What happens when all of the numbers in the list happen to be greater than 100? Also, previous answer exits the loop prematurely as soon as any number equal or smaller than 100 is located. To locate the smallest number in a list, the entire list must be compared with the current best, which is initially taken to be the first number in the list.

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Draw a program flowchart to find the least number in a list of 100 numbers?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

How do you make an input program that computer can determine the highest number?

Here it is in Java for 5 numbers: (adapt for your programming language) import java.util.Arrays Public class Highestnumber { public static void main (String args[]) { Scanner input = new Scanner( System.in ); int numberofinputs = 5; //make an array to hold the numbers int numbers[] = new Int[numberofinputs]; for (x=0;x&lt;numberofinputs;x++) { System.out.print("Please input a number: "; numbers[x] = input.nextInt(); } //Sorts Numbers from least to greatest Arrays.sort(numbers[]); //gets highest number int highestnum = numbers[numberofinputs-1] //displays highest number System.out.println("The highest number is:" + highestnum); } }


Even number program?

bool is_even(long int num) { return !(num &amp; 1); //when the number is even(divisible by two), //its least significant bit is 0 }


Write a program that takes 5 numbers 1 to 10 from user and then prints the number of distinct values?

The simplest solution is to use a std::set&lt;size_t&gt; sequence container to store the values as they are input. Duplicate entries are ignored automatically, thus when all 5 numbers have been input, the set will have at least 1 number but no more than 5. Thus the size of the set represents the count of distinct values that were input.


What does product of a number mean?

There is no such thing as the product of just one number, a product is when 2 or more numbers are multiplied. The product of a number and another number means the answer you get when you multiply the two.


How do you write a looping program to check whether input is a buzz number or not?

Buzz numbers are aircraft identification numbers that were applied to American aircraft following the second world war and through the 1960's. To determine if an input is a buzz number or not, the input must consist of a two- or three-letter manufacturing code and a 3-digit number, separated by a hyphen. The digits are generally the last three digits of the aircraft serial number. Validating the manufacturing code is relatively simple given there were only 173 issued. However, validating the three-digit code would be impossible without a complete list of all aircraft that were assigned a buzz number. If such a list exists, storing them in sequential order would allow your program to perform a fast binary search to determine if the input were valid or not. In the absence of such a list, the manufacturing code alone would at least tell you which type of aircraft the buzz number (if valid) would have applied to.

Related questions

Draw a flowchart to find the least in ten numbers?

factorial


What are the least numbers?

the least number in the world is -transfinite number


What is the least number that is divisible by four different prime numbers?

the least number is 210 which is divisible by four different prime numbers.


What is Least whole number?

One is the least of the whole numbers.


What is the least whole number?

There is no least whole number: the negative counting numbers go on for ever.


What is greatest and least number?

To be honest, numbers go on and on. (they never stop). So it's infinite. The least number would be Negative ( - ) About zillions of digits of numbers.


How does a number line help compare numbers?

order the numbers from least to greatest


What is the least number in single digit numbers?

0


What is the least common multiple of 22?

You need at least two numbers to find an LCM. The LCM (least common multiple) is the smallest positive whole number exactly divisible by two or more whole numbers.


What is the least number of 2 3 and 4?

2 is the least of the three given numbers.


Least Common Multiple15?

You need at least two numbers to find an LCM.


What is the product of the three greatest whole number and the two least whole number?

There are no greatest hole numbers nor least whole numbers so the question makes no sense.