CS FundamentalsHardService-company placement · ISTQB-style
A leap-year function follows the Gregorian rule (divisible by 4, except centuries, unless divisible by 400). Which test set has one year from each of the four input partitions?
- A. 1600, 2000, 2024, 2023
- B. 2400, 1900, 2000, 2021
- C. 1900, 2100, 2024, 2023
- D. 2000, 1900, 2024, 2023
Correct answer: D. 2000, 1900, 2024, 2023
The partitions are: divisible by 400 (2000), by 100 but not 400 (1900), by 4 but not 100 (2024), and not by 4 (2023). The other sets repeat a partition, for example 1600 and 2000 are both divisible by 400.
Practise more Software Engineering, Git and Cloud Basics questionsSoftware Engineering, Git and Cloud Basics: notes and key points
More Software Engineering, Git and Cloud Basics questions
- On main, git revert HEAD~3..HEAD is run with no conflicts. What happens?
- main receives feature work only through merge commits (git merge --no-ff), plus a few direct hotfix commits. What does git log…
- What does this code print (lines joined by ' / ')? python handlers = {'+': lambda a, b: a + b} def fallback(): print('fallback') return…
- A Python app keeps a shared Settings object at module level in settings.py as a singleton. Most code imports it as app.settings, but one…
- What does this code print? python class Count: def init(s, n): s.i = 0; s.n = n def iter(s): return s def next(s): if s.i >= s.n: raise…
- In a strictly layered system, 80% of requests pass through the business and service layers unchanged, which merely forward each call to…