Python Data Types: Integers, Floats, Strings

Building on the Programming Python Variables lesson, you will continue to develop your Python programming skills by learning about data types: integers, floats, and strings. Python data types are important because they allow you to manipulate and analyze data efficiently.

In this lesson, you’ll learn how to work with numerical and text data. You’ll also learn about the two types of numerical data types in Python—integer and float—and how to convert from one type of numerical data type to another using either the int() or float() functions. Toward the end of the lesson, you’ll learn how to manipulate text, or “string” data.

As you learn about strings, you’ll learn how to link or concatenate two or more strings together to form a single string. Working with strings and manipulating them is part of data cleaning, a crucial skill for data scientists because as real-world data from datasets isn’t always the cleanest. You’ll learn more about working with strings in future lessons as well as in our data cleaning advanced course.

While learning about Python data types, you’ll work with mobile app store data and use companies’ mottos to practice storing data to variables.

Objectives

  • Learn how to process numerical data
  • Learn how to process text data
  • Learn how to convert data types

Lesson Outline

  1. Integers and Floats
  2. Conversion Between Types
  3. Strings
  4. Escaping Special Characters
  5. String Concatenation
  6. String Conversion
  7. Multi-line Strings
  8. Review
  9. Takeaways

Get started for free

No credit card required.

Or With

By creating an account you agree to accept our terms of use and privacy policy.