Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

kindly solve for ubuntu in c language Create 3 files - main.c - functions.c - header.h header.h file contains following function prototypes void sort(int array

image text in transcribed

kindly solve for ubuntu in c language

Create 3 files - main.c - functions.c - header.h header.h file contains following function prototypes void sort(int array [], bool order) void findHighest(int array[], int postion) void print(int array[]) functions.c file contains following 3 functions along with their logic void sort(int array[], bool order) \{ > sort in ascending order if order is true > sort in descending order if order is false void findHighest(int array[], int nth)\{ > find nth highest value if nth =2 find 2 nd highest value from the array \} In main.c you will accept command line arguments including 3 things - an array of integers - order of sort ( 1 for ascending order and 0 for descending order) - nth position to get the nth highest number from the array Use makefile to execute all these files. Your makefile will look like this. main: main.o functions.o gcc main.o functions.o -o main main.o: main.c gcc -c main.c functions.o: functions.c gcc -c functions.c clean: rm.0 main

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

Professional Microsoft SQL Server 2014 Integration Services

Authors: Brian Knight, Devin Knight

1st Edition

1118850904, 9781118850909

More Books

Students also viewed these Databases questions

Question

What is carpal tunnel syndrome?

Answered: 1 week ago

Question

=+j Improve the effectiveness of global and virtual teams.

Answered: 1 week ago