1
1
mirror of https://github.com/theoludwig/programming-challenges.git synced 2024-07-18 02:20:12 +02:00
programming-challenges/scripts/languages-wrapper/execute.py

14 lines
402 B
Python

import os
import json
from solution import solution
current_directory = os.path.dirname(__file__)
input_path = os.path.join(current_directory, "input.json")
output_path = os.path.join(current_directory, "output.json")
with open(input_path, "r") as file_content:
input_json = json.load(file_content)
with open(output_path, "w") as file_content:
json.dump(solution(*input_json), file_content)