5 exercises — choosing if, when, unless, and provided-that correctly in runbooks, error messages, API docs, and post-mortems.
0 / 7 completed
1 / 7
A runbook says: "__ the health check fails three times consecutively, the load balancer removes the instance from the pool." Which word correctly begins this conditional for a documented, repeatable procedure?
"When" is the best choice for a documented operational procedure that describes what always happens under a specific condition. In technical documentation, when implies "every time this occurs" — it's a statement of system behaviour, not speculation. If implies uncertainty: "this may or may not happen." Compare: "When the token expires, the client must re-authenticate" (documented behaviour, always happens) vs "If the token is malformed, return 401" (conditional case that may or may not occur). In runbooks and system documentation, prefer when for automated system responses and documented protocols. Use if for troubleshooting scenarios where the condition is uncertain. Option C ("Unless") means "except if" — negative conditional, changes the meaning. Option D ("Provided") is overly formal.
2 / 7
An error message in the application reads: "__ you see this error, check that the DATABASE_URL environment variable is set correctly." Which conditional starter is most appropriate for a user-facing error message?
"If" is the standard choice for user-facing error messages and troubleshooting instructions. Error messages address a specific scenario the user may be experiencing right now — it's not describing a universal behaviour, but a particular case. "If you see this error, check…", "If the connection fails, verify…", "If authentication fails, ensure your credentials are valid." Option A ("When") would imply this error always occurs under this circumstance — too strong for an error message. Option C ("Should") is a more formal conditional often seen in API documentation: "Should this error occur, contact support." It's correct but slightly more distant in tone — better for formal docs than inline error messages. Option D ("Unless") is a negative conditional — wrong here.
3 / 7
An API reference uses a hypothetical scenario: "__ you need to support multiple regions, you would configure a separate replica set for each." Which form creates the correct hypothetical (second) conditional?
"If" starts a standard second conditional here — but context matters. A second conditional uses: If + past tense, would + base verb. "If you needed to support multiple regions, you would configure…" — this is the hypothetical/advisory form. However, the sentence as given uses "need" (not "needed") and "would configure" — making it a first conditional with advisory tone. In technical documentation, the first conditional (If + present, present/will) is more common for advice and guidance: "If you need to support multiple regions, configure a separate replica set." Second conditionals appear when describing scenarios that are unlikely or theoretical. Option B ("Were you to") is a formal inversion of the second conditional — grammatically correct but overly formal for API docs. Option C ("Should") is also a formal inversion: "Should you need to support multiple regions, configure…" — acceptable in formal API reference.
4 / 7
A post-mortem root cause analysis states: "__ the rate limiter been enabled, the cascade failure would not have occurred." Which conditional type and form is this?
The original sentence uses an inverted third conditional — a formal alternative to the standard form. Standard form: "If the rate limiter had been enabled, the cascade failure would not have occurred." Inverted form (formal): "Had the rate limiter been enabled, the cascade failure would not have occurred." Both are correct. The third conditional (If + past perfect, would have + past participle) refers to a hypothetical past — something that did not happen and its imagined consequence. Post-mortems frequently use the third conditional to discuss what could have prevented the incident: "If the circuit breaker had triggered, the downstream services would not have been overwhelmed." Option B is the second conditional — for hypothetical present/future. The distinction is crucial in post-mortems: use the third conditional for past counterfactuals.
5 / 7
A deployment guide states: "__ you follow these steps in order, the migration will complete without data loss." Which conditional conjunction is most appropriate here?
"Provided that" is the most precise choice here. It means "on the condition that" and signals a required dependency: "Provided that you follow these steps in order, the migration will complete without data loss." This is more emphatic than if — it stresses that following the steps is a prerequisite, not optional. Other alternatives: As long as, So long as, On condition that — all carry the same nuance of strict prerequisite. Option B ("If") is grammatically correct and more common, but less emphatic. Option A ("Unless") means "except if you follow" — it reverses the logic and creates a negative conditional ("Unless you follow these steps, data loss will occur" — a valid different sentence). Option D ("Even if") means the outcome holds regardless — the opposite of what is intended here.
6 / 7
You're writing a PR description for a change that automatically scales up server instances based on CPU utilization. The description should start with: 'Should CPU usage consistently exceed 80%, the system will automatically add more instances.' What type of conditional is being employed here?
This question focuses on the second conditional, which describes the *consequence* of a specific condition being met. The sentence clearly states what will happen if CPU usage exceeds 80%. The other options represent different types of conditionals with distinct grammatical structures and meanings – it's crucial to recognize this consequence-driven form.
7 / 7
A Slack message from a senior engineer states: 'Before deploying this change, double-check that the new API key has been correctly configured. If it hasn't, the deployment will fail.' What type of conditional statement is primarily being used here?
This is a third conditional because it describes a hypothetical past situation (the API key not being configured) and its resulting consequence (the deployment failing). Third conditionals are used to talk about unrealized conditions in the past. The other options represent different uses of conditional statements focused on present or future scenarios.
What will I practise in "Conditionals in Technical Contexts — Grammar Exercise"?
Practice if/when/unless/provided-that clauses in IT documentation, runbooks, error messages, and post-mortems. 5 interactive exercises.
How many exercises are in this module?
This module has 7 multiple-choice exercises, each with instant feedback and a full explanation of the correct answer.
Is this exercise free to use?
Yes. Every exercise on CoderSlingo, including this one, is free to use with no account, sign-up, or paywall.
Do I need to create an account to do these exercises?
No account is required. Just click an option to answer — your score for this session is tracked automatically in the progress bar above.
What happens if I choose the wrong answer?
You'll immediately see which answer was correct, plus a full explanation covering the grammar rule and reasoning behind it — mistakes are where most of the learning happens.
Can I retry the exercises if I want a higher score?
Yes — use the "Try again" button on the results screen to reset and go through all the questions again.
Is my progress saved if I close the page?
No. Progress is tracked only for your current visit; reloading or leaving the page resets the counter. This keeps the exercise simple and account-free.
Where can I find more Grammar exercises?
Browse the full Grammar hub for related drills, or check the "Next up" link below to continue with a connected topic.
How is this different from reading an article on the same topic?
Articles explain grammar rules in prose; this exercise tests and reinforces those rules through active recall with immediate feedback — the two work best together.
Who writes these exercises?
Every exercise is written by the CoderSlingo team, drawing on real workplace English used in IT roles, then reviewed for accuracy and clarity.