How we add our function in liabrary as liabrary function.
Exp. we want use our int factorical(int); function as int
pow(int,int); function working in math header file.
Answer / ataraxic
First, implement factorial in standalone module
(factorial.c for example).
Then complie it, create an archive and link it with our
program (my.c for example):
Compilation
1. gcc -c factorial.c -o factorial.o
Archiving
2. ar -rcsv libmy.a factorial.o
Compile our prog with new lib
3. gcc my.c -L. -lmy -lm -o my
| Is This Answer Correct ? | 0 Yes | 2 No |
what is diffrence between string and character array?
how to swap two nubers by using a function with pointers?
Explain what is meant by high-order and low-order bytes?
How can you find the day of the week given the date?
What do you mean by invalid pointer arithmetic?
What is dynamic dispatch in c++?
What is the meaning of ?
You are to write your own versions of strcpy() and strlen (). Call them mystrcpy() and mystrlen(). Write them first as code within main(), not as functions, then, convert them to functions. You will pass two arrays to the function in the case of mystrcpy(), the source and target array.
Which is not valid in C a) class aClass{public:int x;}; b) /* A comment */ c) char x=12;
why TCS selected more student in the software field from all institution.
what is pointer ? what is the use of pointer?
what are the advanced features of functions a) function declaration and prototypes b) calling functions by value or by reference c) recursion d) all the above