Réponse :
Explications :
1) Programme
from random import *
def caractere():
nb=randint(1,3)
if nb==1:
car="a"
elif nb==2:
car="b"
else :
car="*"
return(car)
Console
*** Console de processus distant Réinitialisée ***
>>> caractere()
'a'
>>> caractere()
'b'
>>> caractere()
'*'
>>> caractere()
'b'
>>>