Path: csiph.com!news.mixmin.net!aioe.org!tTqkpX7q/zQujZ+pQ3+Itg.user.gioia.aioe.org.POSTED!not-for-mail From: Dominique Newsgroups: fr.comp.lang.python Subject: Re: En testant les valeurs 5,1,1 obtenu est CONSTRUCTIBLE au lieu dPAS CONSTRUC Date: Wed, 2 Dec 2020 05:58:56 +0100 Organization: Aioe.org NNTP Server Lines: 24 Message-ID: References: NNTP-Posting-Host: tTqkpX7q/zQujZ+pQ3+Itg.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit X-Complaints-To: abuse@aioe.org User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0 Content-Language: fr X-Notice: Filtered by postfilter v. 0.9.2 Xref: csiph.com fr.comp.lang.python:3392 Le 01/12/2020 à 14:14, domxav17 a écrit : > Bonjour, > quelqu'un peut m'aider s'il vous plaît Bonjour, Voilà une solution qui marche : def ma_fonction(t): if t[0]+t[1]>t[2] and t[1]+t[2]>t[0] and t[0]+t[2]>t[1]: return 'Constructible' elif t[0]*t[1]*t[2]==0: return 'PLAT' else: return 'PAS CONSTRUCTIBLE' t=eval(input()) print(ma_fonction(t)) -- Dominique Courriel : dominique point sextant ate orange en France Esto quod es