Modern Python Projects Transcripts
Chapter: Writing code
Lecture: Different python REPL
0:00 As you write python code, you sometimes need to take it for a spin and
0:03 do some interactive coding.
0:06 By default, You can start the interactive python session, by calling python in your terminal.
0:10 This will start a REPL. REPL stands for Read, Eval, Print, Loop.
0:15 So, it's a program that will read your input, evaluate it,
0:18 print the results and loop again to the first step.
0:22 The standard Python REPL is nice because it comes with Python out of the box,
0:27 but it's very basic, and in the long run,
0:30 it's not convenient to use, in the other versions
0:35 of python. There was not even a tab completion.
0:38 So when I typed na and pressed tab, that would insert the tab instead of
0:43 auto-completing the name variable.
0:46 But if you want to write a for loop,
0:48 you still have to Add the indentation in the next lines by hand, instead of
0:53 your REPL detecting it. So, that's still quite inconvenient.
0:59 So, if you do a lot of this interactive coding,
1:02 there are much better Python REPL alternatives.
1:05 We have ipython, bpython and ptpython. I will talk about each of them in the next 3 lessons.