
CompTIALinux+
Domain 4Objective 3
Python Basics XK0-006 Practice Questions (Page 1)
Part of the Automation, Orchestration, and Scripting domain, which accounts for 17% of the XK0-006 exam. CompTIA does not publish an official question count, but from its 90-minute exam (~35–60 total, ~6–10 in this domain), expect 1–2 from this objective — we provide 19 practice questions to prepare you well beyond it. (estimate)
19questions here
4free pages
7concepts
17%of the exam
Questions 1–5
- 1
A script needs to iterate over a list of IP addresses and print each one with its index. Which loop correctly accomplishes this?
Select an answer first - 2
Which Python data structure stores key-value pairs?
Select an answer first - 3
What is the data type of the value `3.14` in Python?
Select an answer first - 4
A developer needs to install a package from a private repository that requires authentication. The developer is using a virtual environment. Which command should be used to install the package?
Select an answer first - 5
A script needs to store a list of server hostnames and later check if a specific hostname exists in the list. The list may contain duplicate hostnames, but the script only needs to know if a hostname is present. Which data structure is most efficient for this membership test?
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 CompTIA. “XK0-006” is a trademark of its owner, used for identification only.