CPSC 231 Lecture Notes - Lecture 6: Pygame, Sublime Text, Source Code Editor
2 pages85 viewsFall 2018
SchoolUniversity of Calgary
Course CodeCPSC 231
This preview shows half of the first page. to view the full 2 pages of the document.
CPSC 231 - Test and Run Python Codes
There are many ways to run your code for testing, each with its own benefits and
downfalls. Here is a list of the multiple ways you can do this, along with how to set-
up each one:
IDLE: IDLE (Python 3.6) is a great program because it is very easy to run your code
while you are creating it, without ever changing windows. Although it is not very
visually appealing and does not colour-code as well as other editors, your code can
be run within seconds. As soon as you would like to test something, simply CTRL +
S (saves the file), then CTRL + F5. This will open a Python shell, and your program
will be run within it. Directions for installing can be found here:
Supports Pygame: yes
Interface and Learning Curve: 5/5 - easy to start using
Sublime Text 3: Sublime Text 3 is one of the best programs for writing code
available. With multiple built-in customization options, and hundreds more available
for download, it is one of the most aesthetically pleasing ones out there. Sublime
Text is also not just limited to Python, it can be used for virtually any programming
language. However, it is not possible to run Python code within the program right off
the bat, but this can be fixed by setting up a sublimeREPL:
If you do not have the patience or time to do this, Sublime Text 3 is still highly
recommended for its great interface. Simply write your code in this amazing editor,
then run it using another method.
Supports Pygame: no
Interface and Learning Curve: 3/5 - takes a while to discover all the options, and how
REPL.it: REPL.it is an online code editor that is great if you use multiple machines.
Simply create an account, and have your code available on any computer (provided
you have internet, and your account info). Unlike Sublime Text, it is possible to test
run your code right away, giving you instant feedback. However, Pygame will not
work here. Go to https://repl.it/ and give it a try.
Supports Pygame: no
Interface and Learning Curve: 4/5 - fairly simple to use, takes some time to
understand all features fully
You're Reading a Preview
Unlock to view full version
Loved by over 2.2 million students
Over 90% improved by at least one letter grade.