1.2.2 libraries Flashcards
1
Q
what are libraries?
A
libraries are pre tested and compiled programs that run when needed
2
Q
What are the benefits of libraries?
A
- efficient: they pre written so save effort and time.
- reliable: as the codes are tested and optimised.
- reusable: same library can be used more than one in same and different codes.
3
Q
What are the drawbacks of libraries?
A
- you have to trust the developer to maintain the library.
- using a large library for s smaller task increase the size of the code and make it unoptimised.
4
Q
what is a linker?
A
combine different object files and libraries into an executable file.
5
Q
state the types of linkers
A
- static
- dynamic
6
Q
different between static and dynamic libraries?
A
static: libraries and object files are combined at compile time, creating larger executable file.
dynamic: libraries are combined with object files at run time, allowing for more flexibility but requiring libraries to be present during execution.
7
Q
what are loaders?
A
system tools that load executable files into main memory to be run by the os.