Update color/README.md

This commit is contained in:
2024-11-25 15:32:44 -05:00
parent 396a1adace
commit 3366874c29

View File

@@ -1,5 +1,4 @@
```python
for i, color in enumerate('RGYBMC'):
globals()[color] = lambda text, i=i: f'\x1b[{91 + i}m{text}\x1b[0m'
for i, c in enumerate('RGYBMC'): globals()[c] = lambda s, i=i: f'\x1b[{91+i}m{s}\x1b[0m'
print(R('hello'), G('world'))
```