September 2019
Beginner to intermediate
494 pages
13h
English
Let's see how we can implement various debugging practices while working with PyCharm. In this subsection, we will be working with the example that's included in the Chapter06/Debugging folder of this book's code repository. Specifically, we will consider the main.py file inside this folder, which contains the following code:
def change_middle(my_list): print('Start function') x = int(input('Enter a number: ')) my_list[1] = x print('End function')if __name__ == '__main__': a = [0, 1, 2] b = a change_middle(a) print(a) print(b)
The preceding code is a simple Python program where we can explore the referencing mechanism in Python while learning about PyCharm's debugging functionalities. Either copy the code directly into ...
Read now
Unlock full access