Search Header Logo
Python Data Types

Python Data Types

Assessment

Presentation

Computers

9th - 12th Grade

Practice Problem

Medium

Created by

Michael Kendall

Used 30+ times

FREE Resource

9 Slides • 1 Question

1

Intro to Python Data Types and Variables

Slide image

2

Today's Agenda

  • Objective

  • Do-Now

  • Variables

  • Datat Types

  • Code Pracitce

  • Exit Ticket

  • Q&A / Class Updates

3

Multiple Choice

Question image

The distance in miles from Washington, DC to Atlanta, GA is 648 miles. If there are 5,280 in one mile, convert the distance from DC to ATL in feet. Be prepared to share your work and how you got to your solution.

1

1,200,300 ft

2

6,725 ft

3

3,421,440 ft

4

5,342,224

4

Variables

  • A name for a spot in the computer's memory

  • This value can change while the program runs

  • Different types of data take up different amounts of data

Slide image

5

Try it yourself

Open https://py3.codeskulptor.org and enter the code . What was your output?

Slide image

6

Try it yourself

  • Enter the code and be prepared to share your response. 

Slide image

7

Data types: There are two major categories

  • Numbers  (3.25, 77, 88.0)

  • Strings ( "hello", "name", " 1 + 3")

  • Other categories :

  • Functions

  • List

8

"Strings" 

  • Lets the user type in letters, numbers and words

  • Not used for calculations

  • When doing calculations: be sure to check that your value is a number, not a string

9

str

  • The str function tells python to handle the value in the () as a string, not as a number

10

Floats

  • .A floating point value is represented either as whole plus fractional digits (like decimal values) or as a mantissa plus an exponent.

Slide image

Intro to Python Data Types and Variables

Slide image

Show answer

Auto Play

Slide 1 / 10

SLIDE