I am trying to run a stand-alone python file partitions.py that is in my home folder. When I type the command "python3 partition.py" the script runs.
However, when I type "python3 -m partition.py" it gives me an error "/usr/local/bin/python3: No module named partition.py"
I do not know why this is the case. Any help would be greatly appreciated. Thanks
partition.pylocated in a directory that is in yourPYTHONPATHenvironment variable?partition.py; there is a file namedpartition.py. The corresponding module is namedpartition, which is what the-m flag expects. Please see the linked duplicate for a full overview of-m`.