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 3 out of 19 pages
Exam (elaborations)

PSU Computer Science 101 Exam 1 Study || Most Recent Exam Actual Complete Real Exam Questions And Correct Answers (Verified Answers) Already Graded A+ | Guaranteed Success!! Newest Exam | Just Released!!

Document preview thumbnail
Preview 3 out of 19 pages

PSU Computer Science 101 Exam 1 Study || Most Recent Exam Actual Complete Real Exam Questions And Correct Answers (Verified Answers) Already Graded A+ | Guaranteed Success!! Newest Exam | Just Released!! PSU Computer Science 101 Exam 1 Study || Most Recent Exam Actual Complete Real Exam Questions And Correct Answers (Verified Answers) Already Graded A+ | Guaranteed Success!! Newest Exam | Just Released!! PSU Computer Science 101 Exam 1 Study || Most Recent Exam Actual Complete Real Exam Questions And Correct Answers (Verified Answers) Already Graded A+ | Guaranteed Success!! Newest Exam | Just Released!! PSU Computer Science 101 Exam 1 Study || Most Recent Exam Actual Complete Real Exam Questions And Correct Answers (Verified Answers) Already Graded A+ | Guaranteed Success!! Newest Exam | Just Released!!

Content preview

PSU Computer Science 101 Exam 1 Study || Most Recent
Exam 2026-2027 Actual Complete Real Exam Questions
And Correct Answers (Verified Answers) Already Graded
A+ | Guaranteed Success!! Newest Exam | Just Released!!




Which Python statement correctly initializes a dictionary data
structure?
a. positions = {"Chad": "1st base", "Cindy": "2nd base", "Tim":

"Outfield"}
b. positions = ["Chad": "1st base", "Cindy": "2nd base", "Tim":

"Outfield"]
c. positions = dictionary("Chad": "1st base", "Cindy": "2nd

base", "Tim":
"Outfield")
d. positions = [["Chad", "1st base"], ["Cindy", "2nd base"],

["Tim", "Outfield"]] - ANSWER -a. positions = {"Chad": "1st
base", "Cindy": "2nd base", "Tim": "Outfield"}


When creating a Python dictionary, _____.
a. you provide keys, which must be integers, and values of any

data type
b. you must provide three items for each entry, separated by

colons
c. you provide values that are used to look up associated keys

d. you provide keys that are used to look up associated values -

ANSWER -d. you provide keys that are used to look up
associated values

,What should you place in the blank in the Python code below
if you want to
display the price for the cat
figurine?


figurinePrices = {"dog": 3.55, "cat": 4.15, "dolphin":
5:65, "turtle":4.25}
print(_____)


a. "The cat costs", figurinePrices("cat")

b. "The cat costs", figurinePrices["cat"]

c. "The cat costs", figurinePrices[1]

d. "The cat costs", figurinePrices[3] - ANSWER -b. "The cat

costs", figurinePrices["cat"]


Which statement will add a new key, "Unit 5", and its associated
value, "Josip",
to the Python dictionary called
residents?
residents = {"Unit 1": "Marley", "Unit 2": "Bruce", "Unit 3":
"Ramesh", "Unit 4":
"Ivy"}


a. residents["Josip"] = "Unit 5"

b. residents.append("Unit 5", "Josip")

c. residents["Unit 5"] = "Josip"

d. residents = {"Unit 5": "Josip"} - ANSWER -c. residents["Unit

5"] = "Josip"

, The following Python code creates a dictionary called marbles
and then _____.


marbles = {"Red": 10, "Tiger Eye": 3, "Blue": 8,
"Green": 5}
marbles["Green"]
=6


a. changes the value associated with the key "Green" to 6

b. adds a second key-value pair with the key "Green" to it

c. removes the "Green": 5 key-value pair from it

d. causes a key error to occur - ANSWER -a. changes the value

associated with the key "Green" to 6


Which statement represents the correct way to initialize the
variable middle_initial with the value of the capital letter S
using the standard Python convention?
a. middle_initial = _S_

b. middle_initial = "S"

c. middle_initial < S

d. middle_initial = S - ANSWER -b. middle_initial = "S"



Which statement describes the punctuation conventions used
for character data in Python?
a. When you initialize or assign a character literal to a
variable, the convention is to surround the literal with double
quotes.
b. When you initialize or assign a character literal to a
variable, you are not allowed to use single quotes.

Document information

Uploaded on
March 5, 2026
Number of pages
19
Written in
2025/2026
Type
Exam (elaborations)
Contains
Questions & answers
$27.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.
nyagajoseph539
3.8
(54)
Sold
249
Followers
14
Items
10806
Last sold
2 hours 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