Path: ...!news.mixmin.net!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Dominique Newsgroups: fr.sci.maths Subject: =?UTF-8?Q?Re=3A_Exercice_niveau_6_=C3=A8me?= Date: Wed, 26 Jul 2023 04:13:19 +0200 Organization: A noiseless patient Spider Lines: 21 Message-ID: References: <64bf757d$0$6427$426a74cc@news.free.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Date: Wed, 26 Jul 2023 02:13:19 -0000 (UTC) Injection-Info: dont-email.me; posting-host="56cf5767fed8b20faa9a2272434dd6b4"; logging-data="1344459"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18tdV/CeGX5aTORm/yTPrZX3fe8MJVQLiw=" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:KIu+pKb8cx67pRGYcGrMWezkC2Y= Content-Language: fr In-Reply-To: <64bf757d$0$6427$426a74cc@news.free.fr> Bytes: 1541 Le 25/07/2023 à 09:10, ast a écrit : > Un exercice donné à des 6 ème que tous les parents > ne savent pas faire, même ceux ayant fait des maths. > > Trouvez un nombre à 4 chiffres tel que si on > l'additionne à la somme de ses 4 chiffres on > trouve 2000. Sans mathématique, mais avec un bout de code Python, on trouve 1981 très facilement : for x in range (1000,10000): if sum([int(y) for y in str(x)])+x==2000: print(x) -- Dominique Courriel : dominique point sextant ate orange en France Esto quod es