Probleme fonction class python

Fermé
Steph - Modifié le 19 avril 2020 à 17:55
yg_be Messages postés 22844 Date d'inscription lundi 9 juin 2008 Statut Contributeur Dernière intervention 2 juin 2024 - 20 avril 2020 à 08:53
Bonjour,

J'ai un bog avec mon programme python quelqu’un peu m'éclairer.

---------------------------------------------------------------------------
UnboundLocalError Traceback (most recent call last)
<ipython-input-242-f957f11382b9> in <module>
----> 1 hh.Bissection()

<ipython-input-237-da95d6f2afc8> in Bissection(soi)
23 #
24 E=1.0
---> 25 if (f1(xb)*f1(xh)) > 0.0:
26 xm2 = "La solution n\'est pas bornée"
27 elif f1((xb+xh)/2) == 0.0:

UnboundLocalError: local variable 'xb' referenced before assignment
A voir également:

1 réponse

yg_be Messages postés 22844 Date d'inscription lundi 9 juin 2008 Statut Contributeur Dernière intervention 2 juin 2024 1 473
19 avril 2020 à 21:42
bonjour, nous montres-tu tout ton programme?
0
Finalement j’ai reussi
0
yg_be Messages postés 22844 Date d'inscription lundi 9 juin 2008 Statut Contributeur Dernière intervention 2 juin 2024 1 473 > Steph
20 avril 2020 à 08:53
peux-tu alors marquer la discussion comme résolue?
0