Created
December 18, 2022 09:12
-
-
Save omargfh/4a91d2102514530f4825e19df4940a6a 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
d = dict() | |
runningTotal = {a:b for (a, b) in zip(d.keys(), [0] + reduce(lambda x, y: x+[x[-1]+y], d.values(), [0])[1:-1])} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment