Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

Python 

Get dict out of list

Hey guys, probably a noob question but I have a list wich contains a dict; [{"mood":"fustrated","reason":"shit ain't working"}]
Like that, how do I get it to be just a dict? {"mood":"fustrated","reason":"shit ain't working"}

Thanks in advance!
You'd take the 0 index of that list. That would be the dictionary itself
I was also thinking that, I was fustrated why it didn't work.. Later I saw it was a string representation of a dict in a list   🤮
It's solved now, thanks.


Possibly Related Threads...
Thread / Author Replies Views Last Post
[Python] by CodeAssassinMay 6, 2020 04:16 AM 5 110 May 6, 2020 04:16 AM
Last Post: SIM-4378207
[Python] by degadoMar 5, 2020 10:43 AM 2 121 Mar 5, 2020 10:43 AM
Last Post: degado
[Python] by Ineed2learn2eatJul 13, 2017 10:48 AM 3 230 Jul 13, 2017 10:48 AM
Last Post: Ineed2learn2eat