# h2.py (commnent: #) def main(): ''' (comment by triple quote string) input: built-in function: prompt the user for input [1] output a prompt ("hello, darkness my old friend.) [2] get the input value from the user. =: assignment statement: value in the right hand side is assigned to the variable input_string Note: _ can be used in a variable. ''' input_string = input("Please enter a string -> ") ''' Multi-line string. It expands many lines. print: standard built-in function to print arguments to the standard output. f-string in Python. It will evaluate any expression enclosed by { and }. s-sting: {len(input_string)} evaluted to 30 and included in the returned string. ''' print(f"length of the string: {len(input_string)}") ''' ''' print(f"in upper case: {input_string.upper()}") print(f"in lower case: {input_string.lower()}") # main() function ends here. if __name__ == "__main__": main()