Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F9697168
scratch-pickle.py
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
246 B
Subscribers
None
scratch-pickle.py
View Options
import
pickle
favorite_color
=
{
"lion"
:
"yellow"
,
"kitty"
:
"red"
}
# marshall/serialize/pickle
pickle
.
dump
(
favorite_color
,
open
(
"save.p"
,
"wb"
))
# unmarshal/deserialize/unpickle
favorite_color_loaded
=
pickle
.
load
(
open
(
"save.p"
,
"rb"
)
)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Aug 18, 11:01 PM (6 d, 2 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3397339
Attached To
rDLDG Git loader
Event Timeline
Log In to Comment