subject

Write a program that reads decimal numbers from the keyboard. The program reads at least three numbers. 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. Value n is greater or equal to 3. 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

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 20:40
Convert and simplify the following sentences to conjunctive normal form (cnf): (a) (p β†’ (q β†’ r)) β†’ (p β†’ (r β†’ q)) (b) (p ∧ q) β†’ (Β¬p ↔ q) (c) ((p β†’ q) ∧ Β¬q) β†’ Β¬p
Answers: 3
question
Computers and Technology, 22.06.2019 00:30
Jenny wants to look at row 345 and compare it to row 17. what can she do if she wanted to easily adjust to see both at once?
Answers: 3
question
Computers and Technology, 22.06.2019 19:20
Write a program that reads a file consisting of students’ test scores in the range 0–200. it should then determine the number of students having scores in each of the following ranges: 0–24, 25–49, 50–74, 75–99, 100–124, 125–149, 150–174, and 175–200. output the score ranges and the number of students. (run your program with the following input data: 76, 89, 150, 135, 200, 76, 12, 100, 150, 28, 178, 189, 167, 200, 175, 150, 87, 99, 129, 149, 176, 200, 87, 35, 157, 189.)
Answers: 3
question
Computers and Technology, 22.06.2019 23:00
Which type of tab stop is most for weights and measurements?
Answers: 1
You know the right answer?
Write a program that reads decimal numbers from the keyboard. The program reads at least three numbe...
Questions
question
Chemistry, 20.08.2020 01:01
question
Mathematics, 20.08.2020 01:01
question
Mathematics, 20.08.2020 01:01
Questions on the website: 13722363