Brevet (DNB) 2026 — Mathematics general stream, Centres étrangers 18 juin 2026 — exercise 3 : Calculation programs and Scratch (official exam paper)
Statement
Here are two calculation programs:
Program A:
- Choose a number.
- Add 6 to this number.
- Subtract 4 from this number.
- Multiply the two numbers obtained.
Program B:
- Choose a number.
- Calculate the square of this number.
- Subtract 9.
1. Choose 1 as the starting number. Verify that the result obtained with program A is $-21$.
2. Choose 10 as the starting number. Calculate the result obtained with program B.
3. Give all possible starting numbers that make it possible to obtain 16 with program B.
4. (Algorithmic question)
The program opposite was designed with the Scratch software.
Copy and complete lines 3, 4 and 5 on your answer sheet so that it displays the result obtained with program A when a starting number is entered.
No justification is expected.
Scratch program to complete:
1. When green flag clicked.
2. Ask « choose a number » and wait.
3. Set variable « Value 1 » to $\text{answer}+\square$.
4. Set variable « Value 2 » to $\text{answer}-\square$.
5. Set variable « Result » to $\square\times\square$.
6. Say by joining « The result of program A is » and the variable « Result ».
5. Choose $x$ as the starting number. Show that the result obtained with program A is $x^2+2x-24$.
6. We want to find which starting number to choose so that programs A and B give the same result. Write an equation that makes it possible to find this starting number, then solve it.
⏳ Solution not generated yet
Open this statement in Expert Maths AI: the step-by-step solution is computed on demand, checked by a second resolution, then published here for everyone.
📝 See the solutionHave a similar exercise? Get it solved step by step, for free.
🧮 Solve my exercise