
GIAC Python Coder
Domain 1Objective 2
Data Structures GPYC Practice Questions (Page 4)
Part of the Python Fundamentals domain, which makes up ~43% of our current practice bank. GIAC (SANS) does not publish an official question count, but from its 120-minute exam (~50–80 total, ~22–34 in this domain), expect 4–7 from this objective — we provide 37 practice questions to prepare you well beyond it. (estimate)
37questions here
8free pages
12concepts
Questions 16–20
- 16
A developer is writing a function that checks whether a given key exists in a dictionary before accessing it. The developer wants to avoid a KeyError. Which code snippet correctly performs this check?
Select an answer first - 17
Why can a tuple be used as a dictionary key, but a list cannot?
Select an answer first - 18
What is the result of the following code? ```python nums = [3, 1, 2] nums.reverse() print(nums) ```
Select an answer first - 19
A DevOps engineer is writing a Python function that takes a dictionary of configuration parameters (which may contain nested lists and dictionaries) and returns a modified copy. The function must NOT alter the original configuration object. The engineer uses the copy module. Which approach guarantees that no nested mutable object in the original is modified?
Select an answer first - 20
What does the dictionary method get() return when the key is not found and no default argument is provided?
Select an answer first
Finished these 5 questions?
Review the revealed explanations, or continue through the curriculum.
Free Basic Practice is a study aid with revealable answers — not a scored exam. Examers.io is independent and not affiliated with or endorsed by GIAC (SANS). “GPYC” is a trademark of its owner, used for identification only.