Grazie.Ho trovato nel frattempo queste istruzioni che funzionano bene :)
https://www.geeksforgeeks.org/convert-json-to-dictionary-in-python/
Ciao

   Il mercoledì 5 ottobre 2022 13:58:42 CEST, Andrea D'Amore <a...@d-amo.re> ha 
scritto:  
 
 On Tue, 4 Oct 2022 at 14:43, Marco <m7...@yahoo.it> wrote:
>    import json
>    data = json.load(open("dati.json"))
>
> ma mi da' un messaggio di errore dicendo che il file non esiste.
> Eppure nel Path Browser della Idle la cartella Documents, dove si trova il 
> file, e' impostata

Non ho idea di cosa sia "Path Browser" secondo IDLE, dai

    import os
    print(os.getcwd())

e vedi dove devi mettere il file da importare, oppure usa un percorso assoluto.


-- 
A.
  
_______________________________________________
Python mailing list
Python@lists.python.it
https://lists.python.it/mailman/listinfo/python

Rispondere a