Write a program that inputs 8 integers and sorts them in a decreasing order. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Write a program that inputs 8 integers and sorts them in a decreasing order.

Solution?

14th Jun 2021, 3:54 PM
Elie G. Medawar
Elie G. Medawar - avatar
2 Answers
+ 2
Elie G. Medawar Not a complete code.Please give the full code and attach the code with your description from code playground.
14th Jun 2021, 4:42 PM
The future is now thanks to science
The future is now thanks to science - avatar
0
#include<iostream> using namespace std; const int size = 8; int a[size]; void main() { int temp; for (int i = 0; i < size; i++) { cout << "enter array element:"; cin >> a[i]; } for (int i = 0; i < size-1; i++) { For (int j=0;j<size-1;j++)
14th Jun 2021, 4:09 PM
Elie G. Medawar
Elie G. Medawar - avatar