What is the purpose of the if __name__ == "__main__": condition in Python scripts?
This condition is used to check whether the Python script is being run as the main program or if it is being imported as a module into another script. Code inside this block will only run if the script is the main program.