79397377

Date: 2025-01-29 16:09:46
Score: 1
Natty:
Report link

I tried to modify the source to store the zen in a variable instead of print. This is dependent on implementation.

import re
from importlib.util import find_spec
from pathlib import Path

zen = ""
zen_module_path = Path(find_spec("this").origin)
zen_source = zen_module_path.read_text()
pattern = re.compile(r'print\((.*)\)')
zen_source_mod = pattern.sub(r'zen = \1', zen_source)
exec(zen_source_mod)
print(zen)

Could also remove the line and decode the s var instead...

Guess I'm not Dutch 🤣

Reasons:
  • Has code block (-0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: french guy