9.Simple Programs to Begin with, Comments and statements, IDEs
Program Format and Structure It is always better to structure your Python program as follows Start with an introductory comment stating the author's name, the purpose of the program and other relevant information.This information should be in the form of comment or document string Then include statements that do the following Import any modules needed by the program Initialize important variables, suitably commented Prompt the user for input data and save the input data in variables Process the input to produce the results Display the results Comments Comments are very important while writing a program. They describe what is going on inside a program, so that a person looking at the source code does not have a hard time figuring it out. You might forget the key details of the program you just wrote in a month's time. So taking the time to explain these concepts in the form of comments is always fruitful. Advantages of Using Comments Using comments in programs makes our code mo...