Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > fr.comp.lang.python > #3887

Re: Comportement étrange avec IN et OR...

From Dominique <zzz@aol.com.invalid>
Newsgroups fr.comp.lang.python
Subject Re: Comportement étrange avec IN et OR...
Date 2022-05-26 11:36 +0200
Organization Aioe.org NNTP Server
Message-ID <t6nhmd$1dos$1@gioia.aioe.org> (permalink)
References <t6ndp3$1igp$1@gioia.aioe.org>

Show all headers | View raw


Le 26/05/2022 à 10:29, Dominique a écrit :

Voici ma variable :
test2=['[22118.286892]',  'i915', '0000:00:02.0:', '[drm]', 
'essai','AUX',  'C/DDI', 'C', '(TC)/PHY', 'TC1:', 'did', 'not', 
'complete', 'or', 'timeout', 'within', '10ms', '(status', '0xad4003ff)', 
  'ERR']

J'ai compris mon erreur. J'utilisais mal OR :

'AUX' in test2 or 'essai' in test2
Out[193]: True

et 'AUX' in test2 and 'ERROR' in test2
Out[196]: False

Les deux réponses deviennent bonnes !

Désolé pour le bruit inutile... mais ça m'a fait progresser...

Bon long weekend pour ceux qui sont concernés,

Dominique


Back to fr.comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Comportement étrange avec IN et OR... Dominique <zzz@aol.com.invalid> - 2022-05-26 10:29 +0200
  Re: Comportement étrange avec IN et OR... Alain Ketterlin <alain@universite-de-strasbourg.fr.invalid> - 2022-05-26 11:27 +0200
    Re: Comportement étrange avec IN et OR... Dominique <zzz@aol.com.invalid> - 2022-05-26 17:26 +0200
      Re: Comportement étrange avec IN et OR... Olivier Miakinen <om+news@miakinen.net> - 2022-05-26 17:52 +0200
        Re: Comportement étrange avec IN et OR... Dominique <zzz@aol.com.invalid> - 2022-05-26 19:01 +0200
  Re: Comportement étrange avec IN et OR... Dominique <zzz@aol.com.invalid> - 2022-05-26 11:36 +0200
  Re: Comportement étrange avec IN et OR... Benoit Izac <use.reply.to@INVALID.ADDRESS> - 2022-05-26 11:38 +0200

csiph-web