• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 4 out of 91 pages
Exam (elaborations)

Cse 6040: Computing For Data Analysis – A Comprehensive 180 Item Practice Final Examination With Evidence-Based Coding Rationales, Data Structure Explanations, Algorithm Breakdowns, And Machine Learning Concepts For Georgia Tech Masters In Analytic

Document preview thumbnail
Preview 4 out of 91 pages

This comprehensive CSE 6040: Computing for Data Analysis practice final examination is designed to help Georgia Tech Master of Science in Analytics students review and apply essential computational concepts used in data analysis. The resource features 180 original practice items covering programming, data structures, algorithms, data manipulation, computational reasoning, and foundational machine learning concepts. Each question is designed to encourage students to understand not only the correct response but also the reasoning behind it. Coding rationales, data-structure explanations, algorithm breakdowns, and conceptual discussions help learners identify why a particular approach works and when alternative approaches may be preferable.

Content preview

CSE 6040: COMPUTING FOR DATA ANALYSIS – A COMPREHENSIVE 180-
ITEM PRACTICE FINAL EXAMINATION WITH EVIDENCE-BASED CODING
RATIONALES, DATA STRUCTURE EXPLANATIONS, ALGORITHM
BREAKDOWNS, AND MACHINE LEARNING CONCEPTS FOR GEORGIA TECH
MASTERS IN ANALYTICS STUDENTS – 2026/2027 CURRICULUM ALIGNED |
100% CORRECT | GUARANTEED PASS

QUESTION 1

You are given a Python list data = [3, 1, 4, 1, 5, 9, 2, 6]. Which of the following code
snippets will produce a new list containing only the unique values in the order they first
appear?

A) list(set(data))
B) sorted(set(data))
C) [x for i, x in enumerate(data) if x not in data[:i]]
D) list(dict.fromkeys(data))
E) Both C and D

Answer: E – Both C and D

Rationale: Option C uses a list comprehension with a slice to check previous
occurrences, preserving order and uniqueness. Option D uses dict.fromkeys(data) which
creates a dictionary with keys from the list, preserving insertion order, then converts to a
list. Option A loses order, Option B sorts the unique values.

Takeaway: To preserve order when deduplicating, use dict.fromkeys() or list
comprehension with membership check.




QUESTION 2

What is the output of the following code?

,python
x = [1, 2, 3]
y = x
y.append(4)
print(x)

A) [1, 2, 3]
B) [1, 2, 3, 4]
C) [4, 3, 2, 1]
D) Error

Answer: B – [1, 2, 3, 4]

Rationale: In Python, lists are mutable objects. When y = x, both variables reference the
same list object. Modifying y modifies the same list that x points to. This is a shallow
copy vs deep copy concept.

Takeaway: Assigning a list to a new variable does NOT create a new list; it creates a
reference to the same list. Use copy() or list() for a shallow copy.




QUESTION 3

Which of the following is NOT a valid Python data type?

A) int
B) float
C) complex
D) decimal

Answer: D – decimal

Rationale: int, float, complex are built-in numeric types in Python. decimal is a module,
not a built-in type (you must import decimal.Decimal). The built-in types include int,
float, complex, bool, str, list, tuple, dict, set, and frozenset.

Takeaway: decimal is a module, not a built-in data type.

,QUESTION 4

What is the output of the following code?

python
a = [1, 2, 3, 4, 5]
print(a[1:4])

A) [1, 2, 3]
B) [1, 2, 3, 4]
C) [2, 3, 4]
D) [2, 3, 4, 5]

Answer: C – [2, 3, 4]

Rationale: List slicing uses the syntax a[start:end] where start is inclusive and end is
exclusive. a[1:4] includes indices 1, 2, and 3 (values 2, 3, 4). Index 4 is excluded.

Takeaway: Slicing is inclusive of the start index and exclusive of the end index.




QUESTION 5

You are given a Python list data = [3, 1, 4, 1, 5, 9, 2, 6]. Which of the following code
snippets will produce a new list containing only the unique values in the order they first
appear?

A) list(set(data))
B) sorted(set(data))
C) [x for i, x in enumerate(data) if x not in data[:i]]
D) list(dict.fromkeys(data))
E) Both C and D

Answer: E – Both C and D

Rationale: Option C uses a list comprehension with a slice to check previous
occurrences, preserving order and uniqueness. Option D uses dict.fromkeys(data) which
creates a dictionary with keys from the list, preserving insertion order, then converts to a
list. Option A loses order, Option B sorts the unique values.

, Takeaway: To preserve order when deduplicating, use dict.fromkeys() or list
comprehension with membership check.




QUESTION 6

What is the difference between list.append() and list.extend()?

A) append() adds a single element; extend() adds multiple elements from an iterable
B) append() adds multiple elements; extend() adds a single element
C) They are the same
D) append() only works with integers

Answer: A – append() adds a single element; extend() adds multiple elements from
an iterable

Rationale: append() adds its argument as a single element to the end of the list.
extend() iterates over its argument (which must be an iterable) and adds each element
to the list. For example, [1,2].append([3,4]) gives [1,2,[3,4]] while [1,2].extend([3,4]) gives
[1,2,3,4].

Takeaway: append() adds one item; extend() adds each item from an iterable.




QUESTION 7

What is the output of the following code?

python
data = {'a': 1, 'b': 2, 'c': 3}
print(data.get('d', 0))

A) 0
B) 1
C) KeyError
D) None

Answer: A – 0

Document information

Uploaded on
August 19, 2026
Number of pages
91
Written in
2026/2027
Type
Exam (elaborations)
Contains
Questions & answers
$26.99

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.
Doctordih
4.9
(488)
Sold
83
Followers
41
Items
1784
Last sold
1 week 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