Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

a. 2. Write a simple library and a makefile to make the following codes. Your library consists of 3 functions: i. add(x,y): adds integers x

image text in transcribed

a. 2. Write a simple library and a makefile to make the following codes. Your library consists of 3 functions: i. add(x,y): adds integers x and y ii. multiply(x,y): multiplies integers x and y iii. factorial(x): calculates x factorial b. Write each function to a different file: add(), multiply(), factorial() functions in files add.c, mult.c, fact.c respectively. Write a main program named progl.c to read a,b,c and calculate a*b+c! using your library functions d. Write a makefile i. Write 3 rules to make add.o, mult.o, fact.o ii. Write a rule to make the executable progl.exe First run the rules to make your library (add.o, mult.o, fact.o). Then run the rule to make your program. Run the executable code and check the result. Submit all your codes, and screenshots. c. e. f. g

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

Filing And Computer Database Projects

Authors: Jeffrey Stewart

2nd Edition

007822781X, 9780078227813

Students also viewed these Databases questions

Question

Create a Fishbone diagram with the problem being coal "mine safety

Answered: 1 week ago