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
Document preview thumbnail
Preview 4 out of 52 pages
Exam (elaborations)

CSE 2421 Midterm 1 Exam Questions With Complete Answers 100% Pass

Document preview thumbnail
Preview 4 out of 52 pages

CSE 2421 Midterm 1 Exam Questions With Complete Answers 100% Pass ...

Content preview

CSE 2421 Midterm 1 Exam Questions With Complete
Answers 100% Pass



UNIX - ANSWER -Proprietary

-AT&T, Bell Labs

-Bourne Shell

-Solaris, macOS, HP-UX

-Not portable




Linux - ANSWER -Open source

-Linus Torvald

-BASH(Bourne Again Shell)

-Debian, Ubuntu, Fedora, Android

-Portable




What made UNIX different from all other commercially available software systems when it
was initially developed? - ANSWER UNIX was different from other software's at the time
because it only needed one portion of code changed per system called the kernel. Originally,
OSs had to be completely rewritten for every system.




What was the C programming language initially created? - ANSWER C was originally
developed to help create the UNIX OS and its utilities

,How is white space (tabs/newlines/returns, spaces, etc.) handled within a C program file? -
ANSWER White spaces are generally ignored by the C compiler. I believe this is a good thing

because all white space adds is readability for humans




What does the command cd cse2421 do? - ANSWER Changes the current working directory to

cse2421




What does the command cd ~ do? - ANSWER Changes the current working directory to your
home-directory




What does the command wc lab1.c do? - ANSWER Counts number of lines/words/characters
in a file




What does the man command allow you to do? - ANSWER Reads the online manual for the
current version of a command




What does the command mv file1 file2 do? - ANSWER Changes the name of file1 to file2




What is the format for the mv command? - ANSWER mv [options] source destination




What does an asterisk(*) specify in a file name? - ANSWER The asterisk specifies all files

,Can the second parameter of a mv command legally be a directory name? - ANSWER Yes




If you put an & character at the end of your command, what happens? - ANSWER Linux opens
a new command window and launches the command in that window




Why aren't open source systems always free? - ANSWER Corporate support versions and
specially modified versions cost a premium

Free as in freedom, not free




Differences between C and Java - ANSWER -C does not support the notion of classes or
objects, in an object-orientated sense

-C does not support encapsulation as all memory is modifiable/executable

-does not support inheritance

-procedure-orientated, not object-orientated

-compiled, not interpreted like java

-C has functions, java has methods

-C is not portable(platform dependent), where java is portable

-developed in early 70s vs 1995 for java




Compile time errors (static errors) - ANSWER Errors found during compilation

e.g. syntax errors

, Run time errors (dynamic errors) - ANSWER Errors found while running the program

e.g. logical or semantic errors




Four categories of statements - ANSWER 1. Declarations

2. Data movement

3. Arithmetic/Logical operations

4. Control flow




Preprocessor directive - ANSWER a C program line beginning with # that provides an
instruction to the preprocessor




#define - ANSWER a directive that defines a macro




#ifdef, #ifndef - ANSWER Specialized forms that test whether a name is defined




#endif - ANSWER Preprocessor directive that ends an #ifdef or #ifndef region




#include - ANSWER replaces the directive with the content of the file whose name is listed in
the directive (generally a list of functions prototypes and macros)




4 programs in order that combine to create the gcc command - ANSWER 1. Preprocessor

Document information

Uploaded on
November 10, 2025
Number of pages
52
Written in
2025/2026
Type
Exam (elaborations)
Contains
Questions & answers
$22.49

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

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.
Zayla
3.4
(18)
Sold
134
Followers
13
Items
16870
Last sold
2 days ago



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