initial creation

This commit is contained in:
2025-05-20 11:57:43 -04:00
commit c98b612926
8447 changed files with 1862526 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
#!/usr/bin/env python
animals = ['OWL', 'Badger', 'bushbaby', 'Tiger', 'Wombat', 'GORILLA', 'AARDVARK']
# {KEY: VALUE for VAR ... in ITERABLE if CONDITION}
d = {a.lower(): len(a) for a in animals} # <1>
print(d, '\n')
words = ['unicorn', 'stigmata', 'barley', 'bookkeeper']
d = {w:{c:w.count(c) for c in sorted(w)} for w in words} # <2>
for word, word_signature in d.items():
print(word, word_signature)