Network calculation program written in Python3