This chapter provides an overview of foundational programming concepts, with a focus on Python syntax. It also introduces two different Python IDEs- Spyder and Google Colaboratory.
Topics covered include:
Variables & assignment operators
Basic data types & comments
Arithmetic operators
Concatenation
Input/Output
Relational or comparison operators
Boolean logic & logical operators
Acknowledgements¶
Portions of this chapter are adapted from the “Lab: Programming in Python” and “Lab: Numbers in Python” lab materials developed by Janet Davis for the the CSC 105 “The Digital Age” course.
This chapter also incorporates elements of Corey Pennycuff’s “Intro to Python/Jupyter” Jupyter notebook from CSE 10101 Elements of Computing (Fall 2019).
Definitions and explanations in this chapter are adapted from:
W3Schools, Python tutorials and documentation
Kenneth Leroy Busbee and Dave Braunschweig, Programming Fundamentals: A Modular Structured Approach, 2nd Edition (Rebus Press, 2018)
Setup¶
One of the Python IDE’s we’ll be exploring in this chapter does require a software download. Spyder is " a free and open source scientific environment written in Python, for Python, and designed by and for scientists, engineers and data analysts" (Spyder documentation).
To install Spyder as a stand-alone program: spyder-ide.org
The other Python IDE introduced in this chapter is the web-based Google Colaboratory.
To install Spyder as a stand-alone program: spyder-ide.org
Application¶
Your answers to this chapter’s application questions should be added to the notebook template.
Google Colab link (ND users only)
Submit the Colab link on Canvas for the assignment submission.