Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- tester n
- si : "n" déja testé faux
- ou si : n < 0 ou n > 100000
- return false
- sinon si : n = M
- return true
- sinon :
- - On essaye les opérations -
- si : tester(n + A)
- return true
- sinon si : tester(n - B)
- return true
- sinon si : tester(n * C)
- return true
- sinon si : n % D == 0
- si : tester(n / D)
- return true
- sinon
- "n" est enregistré comme faux.
- return false
Add Comment
Please, Sign In to add comment