0% found this document useful (0 votes)
6 views4 pages

Python Data Types Project With Cover

school project
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views4 pages

Python Data Types Project With Cover

school project
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Python Project on Data Types

Class 11 – Computer Science Project

Submitted by:
Debargha Chatterjee
Class XI
Techno India Group Public School, Mankundu
Session: 2025–26

-------------------------
Teacher’s Signature
Introduction
In Python, data types are used to define the kind of value a variable holds. They are broadly classified
into groups such as Numeric, Sequence, Set, Mapping, and Boolean. Each group contains specific
types with different functionalities.

Classification of Data Types


Python Data Types:

■■■ Numeric → int, float, complex
■■■ Sequence → str, list, tuple
■■■ Set → set, frozenset
■■■ Mapping → dict
■■■ Boolean → bool
■■■ Special → NoneType

Numeric Data Types


Numeric types deal with numbers.

- int → Integer values (positive, negative, zero)


- float → Decimal numbers
- complex → Numbers with real and imaginary parts
x = 10 # int
y = 3.14 # float
z = 2 + 5j # complex

print(type(x))
print(type(y))
print(type(z))

Sequence Data Types


Sequence means an ordered collection of items.

- str → String (text)


- list → Mutable (can be changed)
- tuple → Immutable (cannot be changed)
name = "Python" # str
fruits = ["apple", "mango"] # list
colors = ("red", "blue") # tuple

print(name[0])
print(fruits[1])
print(colors[0])

Set Data Types


Set types represent an unordered collection of unique elements.
- set → Mutable
- frozenset → Immutable
numbers = {1, 2, 3, 3, 2}
frozen = frozenset([4, 5, 6])

print(numbers)
print(frozen)

Mapping Data Types


Mapping types represent key-value pairs.

- dict → Dictionary in Python


student = {"name": "Debargha", "class": 11, "marks": 95}

print(student["name"])
print(student.get("marks"))

Boolean Data Type


Represents True or False values (used in conditions).

- bool → Either True or False


a = 10
b = 5
result = a > b

print(result)
print(type(result))

None Data Type


Represents no value or null.
x = None
print(x)
print(type(x))

Comparison: Mutable vs Immutable Data Types


Mutable Immutable
list, dict, set tuple, str, frozenset

Conclusion
- Numeric → int, float, complex
- Sequence → str, list, tuple
- Set → set, frozenset
- Mapping → dict
- Boolean → bool
- Special → NoneType

Python data types make programming flexible, powerful, and easy to use.

You might also like