some other challenges

This commit is contained in:
Maxime Vorwerk
2024-06-05 16:22:50 +02:00
parent c9764c3f18
commit eec8ec4147
6 changed files with 66 additions and 0 deletions

15
transformation/sol.py Executable file
View File

@@ -0,0 +1,15 @@
#!/usr/bin/python
with open("enc", "r") as f:
while True:
char = f.read(1)
if not char:
break
c = ord(char)
char_1 = chr(c >> 8)
char_2 = chr(c%(2**8))
print(char_1, end='')
print(char_2, end='')
print('\n')