Spaces:
Sleeping
Sleeping
Juditttttttt
commited on
Commit
•
0a8d595
1
Parent(s):
a090a2d
Update pages/exercici7.py
Browse files- pages/exercici7.py +3 -1
pages/exercici7.py
CHANGED
@@ -4,7 +4,9 @@ import streamlit as st
|
|
4 |
st.title("Benvingut al joc Endevina el número secret.")
|
5 |
st.header("Aconsegueix-ho amb el nombre mínim d'intent")
|
6 |
intents = 0
|
7 |
-
secret =
|
|
|
|
|
8 |
st.write(f"Número secret: {secret} (no li diguis a ningú)")
|
9 |
encertat = False
|
10 |
while not encertat:
|
|
|
4 |
st.title("Benvingut al joc Endevina el número secret.")
|
5 |
st.header("Aconsegueix-ho amb el nombre mínim d'intent")
|
6 |
intents = 0
|
7 |
+
secret = None
|
8 |
+
if not secret:
|
9 |
+
secret = random.randint(1,101)
|
10 |
st.write(f"Número secret: {secret} (no li diguis a ningú)")
|
11 |
encertat = False
|
12 |
while not encertat:
|