Question: Please write a C program to solve this question 2. Write a program that reads decimal numbers from the keyboard. Find and display the smallest

Please write a C program to solve this question

Please write a C program to solve this question 2. Write a

2. Write a program that reads decimal numbers from the keyboard. Find and display the smallest number, the second smallest number, and the third smallest number of the set. The program ends if the largest number encountered does not change for n iterations (the largest number does not change for the next n numbers since it changed). The value of n is read from the keyboard. Please enter the value of n: 3 Please enter a demical number: 1.1 The set of the samllest number, the second smallest number and the third smallest number is {1.100000, I, /} Please enter a demical number: 1.2 The set of the samllest number, the second smallest number and the third smallest number is {1.100000, 1.200000, /} Please enter a demical number: 4 The set of the samllest number, the second smallest number and the third smallest number is {1.100000, 1.200000, 4.000000} Please enter a demical number: 2.3 The set of the samllest number, the second smallest number and the third smallest number is {1.100000, 1.200000, 2.300000} Please enter a demical number: 0.4 The set of the samllest number, the second smallest number and the third smallest number is {0.400000, 1.100000, 1.200000} Please enter a demical number: 2.2 The set of the samllest number, the second smallest number and the third smallest number is {0.400000 , 1.100000, 1.200000} Program ended with exit code: 0 Please enter the value of n: 1 Please enter a demical number: 4 The set of the samllest number, the second smallest number and the third smallest number is {4.000000, I, /} Please enter a demical number: 2 The set of the samllest number, the second smallest number and the third smallest number is {2.000000, 4.000000, /} Program ended with exit code: 0

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!