Please enable JavaScript to use CodeHS

Python

Learn how to program in Python, a language that is often used in Data Analysis, Machine Learning, websites like CodeHS, and more!


Printing

How does one display information to the user using their program? One of the ways Python does so is by using print and println

Indexing and Slicing Strings

Every string consists of a certain number of characters (letters, numbers, punctuation, spaces). Each character has an index, which represents the position of the character in the string

Lists

A list is a mutable, heterogenous data type that stores an ordered sequence of things. You can convert lists to strings, and strings to lists.


Check out some other programs

Hangman
Complex Triangle
Castle

Play around with the code

Python is a popular programming language for building the backend of websites. It's also great for data analysis and running scripts. Check out some of the courses you can take to get started!

Excited to start building your own Python Program?