Code returning a different result on runestone vs local
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 35/100
Direzione di ricerca
Start with the pythonds course's GettingStartedwithData page and reproduce the provided snippet in Runestone and a local Python REPL. Compare the execution context and displayed output; done means the page produces the expected Python behavior or clearly explains any intentional difference.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Error reported in course pythonds on page GettingStartedwithData by user UPS [email protected]
In the following code when we print(A) after changing the element in myList - A shows the new value whereas if I run the same code on my local or an online REPL, it prints the same value as before for A
myList = [1,2,3,4]
A = [myList]*3
print(A)
myList[2]=45
print(A)
Output in runestone: [[1, 2, 3, 4], [1, 2, 3, 4], [1, 2, 3, 4]]
[[1, 2, 45, 4], [1, 2, 45, 4], [1, 2, 45, 4]]
Output in local: [1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4]
[1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4]
- Lingua principale
- Python
- Stelle
- 274
- Fork
- 161
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Nessuna guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di RunestoneInteractive/pythonds
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 70/100
RunestoneInteractive/pythonds#109 ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
RunestoneInteractive/pythonds#126 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 52/100
RunestoneInteractive/pythonds#120 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 55/100
RunestoneInteractive/pythonds#103 ·
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 42/100
RunestoneInteractive/pythonds#99 · 5 commenti · 1 reazione ·
Tutte le issue di RunestoneInteractive/pythonds
Issue simili
-
area:space-accuracy good first issue track:data
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
Sara-Managed-Projects/space-radar#904 ·
I maintainer di solito rispondono entro 1 giorno