Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Exam (elaborations)

CIS*2750: MIDTERM EXAM QUESTIONS AND ANSWERS

Rating
-
Sold
-
Pages
5
Grade
A+
Uploaded on
08-08-2025
Written in
2025/2026

CIS*2750: MIDTERM EXAM QUESTIONS AND ANSWERS Parameters of qsort - answer- Void * base, size_t nel, size_t width, int (*compar) (const void*, const void*)) (Pointer to array, element in array, size of elements, comparator function) How does the comparator function work? - answer- Cast the void pointer to the type of pointer in the given array Assign the values of the given parameters to the pointers Subtract a from b If a b, return -1 If b a, return 1 If a == b, return 0 -o flag - answer- Produces an output file -Wall flag - answer- Activates all warnings -pedantic flag - answer- Produces more specific warning -std=c99 flag - answer- Uses the c99 standard to compile gcc - answer- Preprocessor - translate directives "#" into more C code - Use -E Linker - connects you object code to standard (or non standard) libraries default Compiler - converts C code into object code - Use -c Linking Libraries - answer- Use -l(name of library) *no space Use -L to provide a path to a library isn't in the defaults -fPIC flag - answer- Creates a position independent code; use it when creating .o file -shared flag - answer- Created a shared library Name your file .so Allows for one library to be used between multiple applications export LD_LIBRARY_PATH=. - answer- Tells the OS the pwd of the shared library at runtime Make - answer- Program to make repeated tasks easier Makefile - answer- Name of the make program Clean: - answer- Used to delete intermediate files All - answer- Used to List all make commands to run by default CC - answer- Clang or GCC CFLAGS - answer- -Wall -std=c99 -pedantic (all flags used for linking) Rule Format of Makefile - answer- Target: dependencies Command (Ensure tab space in front of the command) Target - answer- What you want to create Dependencies - answer- What you need to run the command (e.g .h files, .c files) Command - answer- Any Unix command Casting Pointers to Their Actual Type - answer- double *double_ptr_a, *double_ptr_b; double_ptr_a = a; double_ptr_b = b; Scripting languages are generally _________ instead of ________ - answer- Interpreted, Compiled Immediate execution allows for ________ ______________ and ________ - answer- Rapid Development, Change Scripting Languages have a ________ - level support for structures and libraries - answer- High What does python use a combination of? - answer- Python uses a combination of compilation and interpretation Process to Execute in Python - answer- Source code is converted into byte code (intermediate form) Byte code is executed by an interpreter Improve performance versus purely interpreted systems Compiled Execution - answer- Source -(Compiler) Executable -(Run) Execution Interpreter Execution - answer- Source -(Interpreter) Execution

Show more Read less
Institution
CIS*2750:
Course
CIS*2750:

Content preview

CIS*2750: MIDTERM EXAM
QUESTIONS AND ANSWERS
Parameters of qsort - answer- Void * base, size_t nel, size_t width, int (*compar)
(const void*, const void*)) (Pointer to array, element in array, size of elements,
comparator function)

How does the comparator function work? - answer- Cast the void pointer to the type
of pointer in the given array

Assign the values of the given parameters to the pointers

Subtract a from b

If a < b, return -1
If b < a, return 1
If a == b, return 0

-o flag - answer- Produces an output file

-Wall flag - answer- Activates all warnings

-pedantic flag - answer- Produces more specific warning

-std=c99 flag - answer- Uses the c99 standard to compile

gcc - answer- Preprocessor - translate directives "#" into more C code - Use -E

Linker - connects you object code to standard (or non standard) libraries default

Compiler - converts C code into object code - Use -c

Linking Libraries - answer- Use -l(name of library) *no space

Use -L to provide a path to a library isn't in the defaults

-fPIC flag - answer- Creates a position independent code; use it when creating .o file

-shared flag - answer- Created a shared library

Name your file .so

Allows for one library to be used between multiple applications

export LD_LIBRARY_PATH=. - answer- Tells the OS the pwd of the shared library at
runtime

, Make - answer- Program to make repeated tasks easier

Makefile - answer- Name of the make program

Clean: - answer- Used to delete intermediate files

All - answer- Used to List all make commands to run by default

CC - answer- Clang or GCC

CFLAGS - answer- -Wall -std=c99 -pedantic (all flags used for linking)

Rule Format of Makefile - answer- Target: dependencies
Command

(Ensure tab space in front of the command)

Target - answer- What you want to create

Dependencies - answer- What you need to run the command (e.g .h files, .c files)

Command - answer- Any Unix command

Casting Pointers to Their Actual Type - answer- double *double_ptr_a,
*double_ptr_b;
double_ptr_a = a;
double_ptr_b = b;

Scripting languages are generally _________ instead of ________ - answer-
Interpreted, Compiled

Immediate execution allows for ________ ______________ and ________ -
answer- Rapid Development, Change

Scripting Languages have a ________ - level support for structures and libraries -
answer- High

What does python use a combination of? - answer- Python uses a combination of
compilation and interpretation

Process to Execute in Python - answer- Source code is converted into byte code
(intermediate form)

Byte code is executed by an interpreter

Improve performance versus purely interpreted systems

Compiled Execution - answer- Source -(Compiler)> Executable -(Run)> Execution

Interpreter Execution - answer- Source -(Interpreter)> Execution

Written for

Institution
CIS*2750:
Course
CIS*2750:

Document information

Uploaded on
August 8, 2025
Number of pages
5
Written in
2025/2026
Type
Exam (elaborations)
Contains
Questions & answers

Subjects

$16.49
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Get to know the seller

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Freshy Oxford University
Follow You need to be logged in order to follow users or courses
Sold
62
Member since
2 year
Number of followers
4
Documents
6986
Last sold
3 weeks ago

3.6

10 reviews

5
3
4
4
3
1
2
0
1
2

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions