Created
December 12, 2017 12:38
-
-
Save laanwj/822e1d8684a7ffc20cf08156654b37f7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
import json | |
class notreallydict(dict): | |
def __init__(self, x): | |
dict.__init__(self, x) | |
self.x = x | |
def items(self): | |
return self.x | |
v = notreallydict([("1","2"),("1","2")]) | |
print(json.dumps(v)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment