Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

CodeSignal

Storing Data in Python Variables

via CodeSignal

Overview

Programs get useful once they can remember information. Here you'll store values inside variables, give those variables clear names, use them in calculations and messages, update them as a program runs, and convert between text and numbers so the data you work with is ready for the task at hand.

Syllabus

  • Unit 1: Creating and Naming Variables
    • Storing Your First Text Value
    • Storing Numbers in Variables
    • Reusing One Variable Twice
    • Renaming for Readability
  • Unit 2: Using Variables in Expressions
    • Adding Two Variables Together
    • Adding a Number to a Variable
    • Storing a Computed Result
    • Combining Three Variables in One Expression
  • Unit 3: Updating and Reusing Variables
    • Swapping One Score for Another
    • Growing the Score with Itself
    • A Shorter Way to Score
    • Handing Out a Score Penalty
  • Unit 4: Converting Text and Numbers
    • Same Look Different Types
    • Turning Text Into Numbers
    • Turning Numbers Into Messages
    • Decimals and the Wrong Tool

Reviews

Start your review of Storing Data in Python Variables

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.