aboutsummaryrefslogtreecommitdiff
path: root/challenge-045/lubos-kolouch/python/ch-2.py
blob: 541dbdb032479511b6583c0069ade54c7bef13fd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/usr/bin/env python
# -*- coding: utf-8 -*-

import sys


def print_own_source_code() -> None:
    """
    Prints the script's own source code to the standard output.
    """
    script_name = sys.argv[0]

    with open(script_name, 'r') as f:
        for line in f:
            print(line, end='')


if __name__ == "__main__":
    print_own_source_code()