Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Want to build the c++ sort function without using library . So I build the code but error code appeared. Can you fix this? The

Want to build the c++ sort function without using library. So I build the code but error code appeared. Can you fix this? The code is shown below

#include

using namespace std;

// build sort function

void fc_sort(int Li[], int size){

for (int i=0; i

for (int j=i+1; j

if ( Li[i] > Li[j]){

Li[i] = Li[j];

}

}

}

for (int i=0; i

cout << Li[i] << " ";

}

}

int main(){

int LL[] = {3,4,5,1,2};

fc_sort(LL, 5);

return 0;

}

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Concepts

Authors: David Kroenke, David Auer, Scott Vandenberg, Robert Yoder

8th Edition

013460153X, 978-0134601533

More Books

Students also viewed these Databases questions

Question

Define self-esteem and discuss its impact on your life.

Answered: 1 week ago

Question

What is Ramayana, who is its creator, why was Ramayana written?

Answered: 1 week ago

Question

To solve by the graphical methods 2x +3y = 9 9x - 8y = 10

Answered: 1 week ago