subject

If someone can rewrite my work in the c program, the task must be accurate. I give I need an answer by tonight. So this is a task: To pseudo-randomly draw 10 numbers, print them in a console and place them in a string of length 10, then take out all the odd numbers in a new string, sort them from the smallest to the largest, and print them in the console.

This is my work. ignore language in printf i just need some changes. Please help!

#include
#include
#include
#include
#include
#include
int main()
{
int i, m=0,niz[10],nizn[10],mz=0,pom;

srand(time(0));

printf("\n Izvlacenje pseudoslucajnih brojeva i popunjavanje niza:");
for( i=0; i<10; i++) {
niz[i]=rand();
printf("\n Izvuceni %d broj niza je %d", i, niz[i]);

}

for( i=0; i<10; i++) {
if(niz[i]%2==1){
nizn[m]=niz[i];
m=m+1;
}
}
printf("\n \n Broj neparnih brojeva je m=%d",m);

printf("\n \n Neparni brojevi novog niza su:");
for( i=0; i nizn[i+1]) {
pom=nizn[i+1];
nizn[i+1]=nizn[i];
nizn[i]=pom;
mz=1;
}
}
if (mz==1) {
goto ponovi;

}

printf("\n\n Sortiranjem neparnih brojeva dobijamo sledeci niz:");
for( i=0; i printf("\n %d clan neparnog niza je %d",i, nizn[i]);
}
return 0;
}

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 15:20
The north and south regions had very diferent economies in the 1800s.
Answers: 1
question
Computers and Technology, 22.06.2019 17:30
The forerunner to cell phones, pdas, and smartphones was
Answers: 1
question
Computers and Technology, 23.06.2019 11:00
This chapter lists many ways in which becoming computer literate is beneficial. think about what your life will be like once you’re started in your career. what areas of computing will be most important for you to understand? how would an understanding of computer hardware and software you in working from home, working with groups in other countries and contributing your talents.
Answers: 1
question
Computers and Technology, 23.06.2019 12:00
Using the list, you can select the number of photos that will appear on each slide. a. theme b. frame shape c. pictures in album d. picture layout
Answers: 1
You know the right answer?
If someone can rewrite my work in the c program, the task must be accurate. I give I need an answer...
Questions
question
Mathematics, 19.02.2021 18:40
question
Mathematics, 19.02.2021 18:40
Questions on the website: 13722363