Advertisements

Bash Scripting Practice Tests: 160 Questions Explained

Advertisements
Bash scripting practice tests: variables, tests, loops, functions, error handling, Vim - every answer explained
1
1/5
(60) Ratings
0 students
Created by Vitalii Shumylo
Advertisements

What you'll learn

  • Check your Bash scripting knowledge across four tests
  • Find your weak areas: script basics, control flow and functions, or advanced Bash and Vim
  • Learn why each wrong option is wrong, not just which option is right
  • Spot the classic Bash traps: unquoted variables, spaces around =, pipes into while loops, a failed cd
  • Practise under time pressure with a full mixed mock exam
This course includes:
160 questions on-demand video
1 articles
0 downloadable resources
1 lessons
Full lifetime access
Access on mobile and TV
Certificate of completion
Advertisements

Course content

Requirements

  • Basic use of the Linux command line (or a Linux VM you are learning on)
  • No lab is needed to take the tests

Description

Are you starting to automate your work with Bash scripts? These practice tests check the knowledge a DevOps engineer or Linux administrator uses every day: writing and running scripts, variables, quoting and redirection, conditions, loops and functions, safe error handling, arrays and background jobs – and editing it all in Vim.

You get 4 practice tests with 160 questions in total (40, 40, 40, 40). Every question was checked twice before release: once by the author against the official documentation, and once by an independent reviewer who answered it blind – any disagreement was settled with a source.

What makes the explanations useful

Each answer tells you why the right option is right and why each wrong option is wrong. The wrong options are real features, commands and settings that are easy to pick by mistake – that is where most of the learning is.

How the tests are built

  • Practice Test 1: Bash Script Basics: Variables, Quoting and Redirection: the shebang, permissions and chmod, variables, quoting, command substitution, special parameters, redirection and file tests.
  • Practice Test 2: Conditions, Loops, Functions and Error Handling: test and [[ ]], comparisons, if and case, for and while loops, read, functions and local variables, exit codes, set -euo pipefail and trap.
  • Practice Test 3: Parameter Expansion, Arrays, Jobs and Vim: parameter expansion, indexed and associative arrays, mapfile, arithmetic, background jobs and wait, subshells, and editing in Vim.
  • Practice Test 4: Full Mock Exam: a mixed exam across all three areas – take it last, in one sitting.

Questions use single-answer and multiple-answer formats; the number of answers to pick is always stated. Suggested time: 60 minutes per test.

Versions: GNU Bash 5.2 and 5.3 on current Linux distributions (Ubuntu 24.04 LTS, RHEL 9/10), GNU coreutils, Vim 9.1, as of October 2026.

Please note: these are original practice questions written by an instructor. This course is not affiliated with or endorsed by the GNU Project or the Free Software Foundation; GNU is a Free Software Foundation trademark, and Linux is a registered trademark of Linus Torvalds.

Who this course is for:

  • Beginners in DevOps and Linux administration who are learning to write Bash scripts
  • System administrators who want to automate routine tasks safely
  • Students of Bash scripting courses who want to test what they learned
Advertisements
E03DE6B6F6F3B76D013D
Advertisements
Advertisements
Free Online Courses with Certificates
Logo
Register New Account