Small turtle Python third lecture exercises

0. Which of the following variables is incorrectly named? Why?

A:MM_520

B:_MM520_

C:520_MM

D:_520MM

Variable naming: consist of letters, underscores, numbers, and start with letters and underscores

 

1. Besides using backslash (\) for character escaping, is there any way to print: Let's go! this string?

a = "Let's go!“

 

Note: This section pays attention to the backslash problem described, add a backslash at the end of the original string, r'xxxxxx''\\' can be

            Long string representation: ''' xxxx

            xxxx'''

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325525349&siteId=291194637