Google IT Automation with Python Certification exam answers 2026: This page lists all 100 questions of the official Google IT Automation with Python Certification exam by Itronix Solutions, each with its four answer options and the correct answer highlighted in green. Use it to revise every topic before you attempt the test and earn your verifiable certificate.
About this certification: It’s designed to teach you how to program with Python and how to use Python to automate common system administration tasks.
| Certification | Google IT Automation with Python Certification |
| Provider | Itronix Solutions |
| Category | Programming & Development |
| Total questions | 100 multiple-choice questions |
| Marks | 1 mark per question (100 marks) |
| Passing score | 80% (80 out of 100) |
| Retake | Available if you do not pass |
| Certificate | Verifiable online certificate |
Take the exam: Google IT Automation with Python Certification on Itronix Solutions. See every other Itronix exam in our complete list of Itronix certification answers.
Google IT Automation with Python Exam Questions and Answers
Questions 1 to 25
1. What is the maximum length of a Python identifier?
Correct answer: A. No fixed length is specified.
2. How is a code block indicated in Python?
Correct answer: B. Indentation.
3. Which of the following concepts is not a part of Python?
Correct answer: C. Pointers.
4. Which of the following statements are used in Exception Handling in Python?
Correct answer: D. All of the above
5. Which of the following types of loops are not supported in Python?
Correct answer: C. do-while
6. Which of the following is the proper syntax to check if a particular element is present in a list?
Correct answer: C. Both A and B
7. Which of the following functions converts date to corresponding time in Python?
Correct answer: B. strptime()
8. As what datatype are the *args stored, when passed into a function?
Correct answer: A. Tuple.
9. What is the maximum possible length of an identifier?
Correct answer: D. None of these above
10. Who developed the Python language?
Correct answer: B. Guido van Rossum
11. In which language is Python written?
Correct answer: B. C
12. What do we use to define a block of code in Python language?
Correct answer: B. Indentation
13. Which of the following statements is correct regarding the object-oriented programming concept in Python?
Correct answer: A. Objects are real-world entities while classes are not real
14. What is the method inside the class in python language?
Correct answer: B. Function
15. Is Python code compiled or interpreted?
Correct answer: A. Python code is both compiled and interpreted
16. Which of the following functions can help us to find the version of python that we are currently working on?
Correct answer: C. sys.version
17. What is the order of precedence in python?
Correct answer: A. Parentheses, Exponential, Multiplication, Division, Addition, Subtraction
18. Which of the following is true for variable names in Python?
Correct answer: B. unlimited length
19. Which of the following is the truncation division operator in Python?
Correct answer: D. //
20. Which of the following functions is a built-in function in python?
Correct answer: A. print()
21. IT automation with Python helps to:
Correct answer: C. Perform repetitive system tasks reliably with scripts
22. A Python script is run from the terminal with:
Correct answer: A. python3 script.py
23. The shebang line #!/usr/bin/env python3 allows:
Correct answer: B. Running a script directly as an executable on Unix
24. chmod +x script.py is used to:
Correct answer: B. Make a script executable
25. The os module provides:
Correct answer: B. Functions to interact with the operating system
Questions 26 to 50
26. os.path.exists(path) checks:
Correct answer: A. Whether a file or directory exists
27. os.listdir(path) returns:
Correct answer: B. A list of entries in a directory
28. os.path.join() is used to:
Correct answer: C. Build file paths correctly for the operating system
29. os.makedirs() creates:
Correct answer: D. Directories, including intermediate ones
30. os.environ provides access to:
Correct answer: C. Environment variables
31. The shutil module is used to:
Correct answer: C. Copy, move and remove files and directories at a high level
32. shutil.disk_usage() returns:
Correct answer: D. Total, used and free disk space
33. The psutil library can report:
Correct answer: B. CPU, memory and process information
34. Opening files with "with open(…) as f:" ensures:
Correct answer: D. The file is closed automatically
35. Mode "w" when opening a file:
Correct answer: B. Writes and overwrites existing content
36. Mode "a" when opening a file:
Correct answer: D. Appends to the end of the file
37. The csv module is used to:
Correct answer: D. Read and write comma-separated value files
38. csv.DictReader returns rows as:
Correct answer: D. Dictionaries keyed by header names
39. The json module’s json.load() reads:
Correct answer: B. JSON data from a file into Python objects
40. The re module is used for:
Correct answer: C. Regular expressions
41. In regex, \d matches:
Correct answer: C. A digit
42. In regex, \w matches:
Correct answer: A. A word character (letter, digit or underscore)
43. In regex, a dot (.) matches:
Correct answer: D. Any single character except newline
44. In regex, * means:
Correct answer: D. Zero or more of the preceding element
45. In regex, + means:
Correct answer: D. One or more of the preceding element
46. In regex, ^ anchors to:
Correct answer: A. The start of a string
47. In regex, $ anchors to:
Correct answer: B. The end of a string
48. re.search() returns:
Correct answer: C. The first match object or None
49. re.findall() returns:
Correct answer: D. A list of all matches
50. Capturing groups in regex are created with:
Correct answer: C. Parentheses ( )
Questions 51 to 75
51. re.sub() is used to:
Correct answer: A. Replace text matching a pattern
52. The subprocess module is used to:
Correct answer: A. Run external commands and programs
53. subprocess.run(["ls","-l"]) executes:
Correct answer: C. The ls -l command
54. capture_output=True in subprocess.run():
Correct answer: A. Captures stdout and stderr
55. A process return code of 0 usually means:
Correct answer: B. Success
56. sys.argv contains:
Correct answer: A. Command-line arguments passed to the script
57. sys.exit(1) is used to:
Correct answer: B. Exit the script with a non-zero (error) status
58. Standard input, output and error are called:
Correct answer: D. stdin, stdout and stderr
59. Redirecting output in Bash with > sends it to:
Correct answer: A. A file, overwriting it
60. A pipe (vertical bar) in Bash:
Correct answer: D. Passes one command’s output as another’s input
61. grep in Linux is used to:
Correct answer: C. Search text for patterns
62. Bash variables are referenced with:
Correct answer: B. $VAR
63. A Bash for loop over files can be written as:
Correct answer: C. for f in *.log; do …; done
64. Python’s requests library is used for:
Correct answer: D. Making HTTP requests
65. requests.get(url).status_code returns:
Correct answer: B. The HTTP response status code
66. HTTP status 200 means:
Correct answer: B. Success
67. The smtplib and email modules help to:
Correct answer: C. Compose and send emails from Python
68. The Pillow (PIL) library is used to:
Correct answer: D. Process and convert images
69. Unit tests verify:
Correct answer: B. Small pieces of code behave as expected
70. The unittest module uses assertions such as:
Correct answer: D. assertEqual
71. pytest is:
Correct answer: D. A popular Python testing framework
72. Test-driven development means:
Correct answer: A. Writing tests before the code that makes them pass
73. Edge cases are:
Correct answer: D. Unusual or boundary inputs that may break code
74. try/except blocks are used to:
Correct answer: A. Handle errors gracefully
75. raise ValueError("msg") is used to:
Correct answer: A. Signal an error condition explicitly
Questions 76 to 100
76. assert statements are used to:
Correct answer: B. Check conditions that must be true during development
77. Git is used in IT automation to:
Correct answer: B. Version control scripts and collaborate
78. git diff shows:
Correct answer: B. Changes between versions
79. git commit records:
Correct answer: B. A snapshot of staged changes
80. Debugging tools like pdb allow:
Correct answer: D. Stepping through code to find problems
81. The logging module is better than print in production because it:
Correct answer: B. Records levels, timestamps and destinations
82. Profiling with cProfile helps to:
Correct answer: A. Find slow parts of code
83. Configuration management tools such as Puppet or Ansible:
Correct answer: B. Automate configuring many machines consistently
84. Infrastructure as code means:
Correct answer: C. Defining infrastructure in version-controlled files
85. Cloud automation can use:
Correct answer: D. APIs and SDKs to provision resources programmatically
86. Virtual environments (venv) isolate:
Correct answer: C. Project-specific Python packages
87. pip install package installs:
Correct answer: B. A Python package from PyPI
88. requirements.txt lists:
Correct answer: A. Python package dependencies for a project
89. Scheduling scripts on Linux is often done with:
Correct answer: A. cron
90. A cron expression "0 2 * * *" runs a job:
Correct answer: B. Every day at 02:00
91. Parsing log files with Python often involves:
Correct answer: B. Reading lines, applying regex and aggregating counts
92. Idempotent scripts can be run:
Correct answer: B. Multiple times with the same result
93. Automation needs error handling and logging because:
Correct answer: D. Unattended scripts must fail safely and be diagnosable
94. Secrets in automation scripts should be:
Correct answer: C. Stored in environment variables or secret managers
95. The main benefit of IT automation is:
Correct answer: C. Saving time and reducing human error in repetitive tasks
96. Memory leaks in long-running scripts can be investigated with:
Correct answer: A. Memory profiling tools
97. glob.glob("*.txt") returns:
Correct answer: A. A list of file paths matching the pattern
98. datetime.datetime.now() returns:
Correct answer: B. The current local date and time
99. f-strings such as f"Hello {name}" are used to:
Correct answer: B. Embed expressions inside string literals
100. A dictionary comprehension like {k: v for k, v in pairs} creates:
Correct answer: B. A dictionary from an iterable
How to Pass the Google IT Automation with Python Exam
- Read every question carefully; most options look similar, so look for the most precise answer.
- Revise the questions above topic by topic rather than memorising letters, because option order can change in the live test.
- You need 80 correct answers out of 100 to pass, so aim to understand at least 85 to stay safe.
- If you do not clear it on the first attempt, review the questions you missed and use the retake option.
Frequently Asked Questions
How many questions are in the Google IT Automation with Python Certification exam?
The exam has 100 multiple-choice questions, each worth 1 mark.
What is the passing score for the Google IT Automation with Python Certification?
You need at least 80% (80 out of 100) to pass and receive the certificate.
Can I retake the Google IT Automation with Python Certification exam?
Yes. If you score below 80%, you can retry the test after reviewing the topics.
Is the Itronix certificate verifiable?
Yes. Every certificate issued by Itronix Solutions has a unique ID that can be checked on the Itronix verify-certificate page.
More Programming & Development Certification Answers
- Advanced Java Certification Exam Answers
- Android Development Certification Exam Answers
- Automation Testing Certification Exam Answers
- Blockchain Certification Exam Answers
- C & C++ Programming Language Certification Exam Answers
- Certified Quality Engineer Professional Certification Exam Answers
- Core Java Programming Professional Certification Exam Answers
- Data Structures and Algorithm Certification Exam Answers
Disclaimer: These answers are provided for learning and revision. Questions and answers are checked regularly; if you find a mistake, let us know in the comments.
Priya Dogra – Free Certifications, Exam Answers & Career Guides Free certification exam answers, courses, scholarships and career guides for learners worldwide