SlideShare a Scribd company logo
1 of 17
Data Structures in
Python
Data Structure
 What is Data Structure?
 Organizing, managing and storing data is important as it enables easier
access and efficient modifications. Data Structures allows you to organize
your data in such a way that enables you to store collections of data, relate
them and perform operations on them accordingly.
 Philosophy
“Clever” ways to organize information in order to enable efficient
computation
Goals
 what the tools are for storing and processing common data
types
 which tools are appropriate for which need
 So that make good design choices as a programmer
 Another Goal is it must be rich in structure to reflect the actual relationship
of data in real world .The structure should be simple enough for efficient
processing of data .
Data
Built-in Data Structure
 Understand Data
 Understand the data according to its Nature.
 Map the data with available structure.
 choosing the right data structure for your data
Three W’s
Why we are using data?
What we are going to do with the data?
Where we are sending data i.e location or container?
Python’s Data structure
Data Structure
Built-in Data
Structure
List Tuples
User Defined
Data Structure
Dictionary Set
Hash Map
Graph
Linked List
Tree
Stack
Queue
Built-in Data structure
List
Dictionary
Tuple
Set
Lists
 This Data structure use for storing and accesing objects which belongs in
a specific sequence.
 Lists are used to store multiple items in a single variable
 Lists in Python are linear containers used for storing data of various Data
Types. The ability to store a variety of data is what makes Lists a very
unique and vital Data Structure in Python.
Examples
 city_list=['Newyork','chicago', 'Los Angeles', 'Houston', 'Philadelphia',
'Dallas']
 squares = [‘1’, ‘4, 9’, ’16’]
 List with Mixed Data types
 My_list = [‘1’ ,”Hello”, ‘3.5’]
Example
 data = [{"id": ("1", "2", "3"), "name": ("Dannie", "Williams"),
"department": ("HR", "IT")},
{"id": ("4", "5", "6"), "name": ("jhon", "smith"),
"department": ("HR", "IT")},
{"id": ("7", "8", "9"), "name": ("Allen", "polard"),
"department": ("finance", "IT")},
{"id": ("10", "11", "12"), "name": ("Reema", "Ferguson"),
"department": ("business", "IT")},
{"id": ("13", "14", "15"), "name": ("patrick", "Donald"),
"department": ("business", "IT")}]
List of Tweets
Features of Lists
 Lists are ordered.
 Lists can contain any arbitrary objects.
 List elements can be accessed by index.
 Lists are mutable.
 Lists are dynamic.
Lists
 Syntax
 List_variables = [ val1,val2,val3…….]
 My_list = [1,2,3]
List Indices
 my_list =[1,2,3,4,5,6,7,8,9,10]
List Methods
 Append()
 Count
 Index()
 Insert()
 Pop()
 Remove()
 Reverse()
 Sort()
 Extend()
 If you want to remember these methods (ASPIRER)

More Related Content

Similar to Data Structures in Python.pptx

Lecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.ppt
Lecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.pptLecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.ppt
Lecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.pptiamsallauddin
 
09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.ppt09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.pptNagarajuNaveena1
 
Data Structures
Data StructuresData Structures
Data Structureshmwwfv1
 
09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.ppt09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.pptMeenakshiPatel13
 
Data Wrangling and Visualization Using Python
Data Wrangling and Visualization Using PythonData Wrangling and Visualization Using Python
Data Wrangling and Visualization Using PythonMOHITKUMAR1379
 
Introduction to Data Structure
Introduction to Data StructureIntroduction to Data Structure
Introduction to Data Structurechouguleamruta24
 
Data structure Assignment Help
Data structure Assignment HelpData structure Assignment Help
Data structure Assignment HelpJosephErin
 
PPT_DATA STRUCTURE.ppt
PPT_DATA STRUCTURE.pptPPT_DATA STRUCTURE.ppt
PPT_DATA STRUCTURE.pptYAZATMishra
 
2. Introduction to Data Structure.pdf
2. Introduction to Data Structure.pdf2. Introduction to Data Structure.pdf
2. Introduction to Data Structure.pdfSulabhPawaia
 
PDS Unit - 1 Introdiction to DS.ppt
PDS Unit - 1 Introdiction to DS.pptPDS Unit - 1 Introdiction to DS.ppt
PDS Unit - 1 Introdiction to DS.pptssuser52a19e
 
Data Structure Introduction for Beginners
Data Structure Introduction for BeginnersData Structure Introduction for Beginners
Data Structure Introduction for Beginnersramanathan2006
 
Unit-1 DataStructure Intro.pptx
Unit-1 DataStructure Intro.pptxUnit-1 DataStructure Intro.pptx
Unit-1 DataStructure Intro.pptxajajkhan16
 
Introduction of Data Structure
Introduction of Data StructureIntroduction of Data Structure
Introduction of Data StructureMandavi Classes
 

Similar to Data Structures in Python.pptx (20)

Python for beginners
Python for beginnersPython for beginners
Python for beginners
 
data structures
data structuresdata structures
data structures
 
Lecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.ppt
Lecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.pptLecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.ppt
Lecture 1 IntroductionToDataStructures_coursematerial_Draft0.01.ppt
 
09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.ppt09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.ppt
 
Data Structures
Data StructuresData Structures
Data Structures
 
09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.ppt09c-DataStructuresListsArrays.ppt
09c-DataStructuresListsArrays.ppt
 
DS_PPT.pptx
DS_PPT.pptxDS_PPT.pptx
DS_PPT.pptx
 
Data Wrangling and Visualization Using Python
Data Wrangling and Visualization Using PythonData Wrangling and Visualization Using Python
Data Wrangling and Visualization Using Python
 
Introduction to Data Structure
Introduction to Data StructureIntroduction to Data Structure
Introduction to Data Structure
 
Data structure Assignment Help
Data structure Assignment HelpData structure Assignment Help
Data structure Assignment Help
 
Database Concepts
Database ConceptsDatabase Concepts
Database Concepts
 
PPT_DATA STRUCTURE.ppt
PPT_DATA STRUCTURE.pptPPT_DATA STRUCTURE.ppt
PPT_DATA STRUCTURE.ppt
 
Ch1
Ch1Ch1
Ch1
 
Database
Database Database
Database
 
2. Introduction to Data Structure.pdf
2. Introduction to Data Structure.pdf2. Introduction to Data Structure.pdf
2. Introduction to Data Structure.pdf
 
PDS Unit - 1 Introdiction to DS.ppt
PDS Unit - 1 Introdiction to DS.pptPDS Unit - 1 Introdiction to DS.ppt
PDS Unit - 1 Introdiction to DS.ppt
 
Data structure
Data structureData structure
Data structure
 
Data Structure Introduction for Beginners
Data Structure Introduction for BeginnersData Structure Introduction for Beginners
Data Structure Introduction for Beginners
 
Unit-1 DataStructure Intro.pptx
Unit-1 DataStructure Intro.pptxUnit-1 DataStructure Intro.pptx
Unit-1 DataStructure Intro.pptx
 
Introduction of Data Structure
Introduction of Data StructureIntroduction of Data Structure
Introduction of Data Structure
 

Recently uploaded

Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...
Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...
Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...Valters Lauzums
 
1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证
1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证
1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证ppy8zfkfm
 
edited gordis ebook sixth edition david d.pdf
edited gordis ebook sixth edition david d.pdfedited gordis ebook sixth edition david d.pdf
edited gordis ebook sixth edition david d.pdfgreat91
 
Seven tools of quality control.slideshare
Seven tools of quality control.slideshareSeven tools of quality control.slideshare
Seven tools of quality control.slideshareraiaryan448
 
Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...
Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...
Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...mikehavy0
 
NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...
NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...
NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...Amil baba
 
一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理pyhepag
 
如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证
如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证
如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证zifhagzkk
 
Formulas dax para power bI de microsoft.pdf
Formulas dax para power bI de microsoft.pdfFormulas dax para power bI de microsoft.pdf
Formulas dax para power bI de microsoft.pdfRobertoOcampo24
 
社内勉強会資料  Mamba - A new era or ephemeral
社内勉強会資料   Mamba - A new era or ephemeral社内勉強会資料   Mamba - A new era or ephemeral
社内勉強会資料  Mamba - A new era or ephemeralNABLAS株式会社
 
Sensing the Future: Anomaly Detection and Event Prediction in Sensor Networks
Sensing the Future: Anomaly Detection and Event Prediction in Sensor NetworksSensing the Future: Anomaly Detection and Event Prediction in Sensor Networks
Sensing the Future: Anomaly Detection and Event Prediction in Sensor NetworksBoston Institute of Analytics
 
如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证
如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证
如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证ju0dztxtn
 
如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一
如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一
如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一fztigerwe
 
Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...
Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...
Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...ThinkInnovation
 
一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理
一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理
一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理pyhepag
 
NOAM AAUG Adobe Summit 2024: Summit Slam Dunks
NOAM AAUG Adobe Summit 2024: Summit Slam DunksNOAM AAUG Adobe Summit 2024: Summit Slam Dunks
NOAM AAUG Adobe Summit 2024: Summit Slam Dunksgmuir1066
 
1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证
1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证
1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证dq9vz1isj
 
What is Insertion Sort. Its basic information
What is Insertion Sort. Its basic informationWhat is Insertion Sort. Its basic information
What is Insertion Sort. Its basic informationmuqadasqasim10
 

Recently uploaded (20)

Abortion pills in Riyadh Saudi Arabia (+966572737505 buy cytotec
Abortion pills in Riyadh Saudi Arabia (+966572737505 buy cytotecAbortion pills in Riyadh Saudi Arabia (+966572737505 buy cytotec
Abortion pills in Riyadh Saudi Arabia (+966572737505 buy cytotec
 
Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...
Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...
Data Analytics for Digital Marketing Lecture for Advanced Digital & Social Me...
 
123.docx. .
123.docx.                                 .123.docx.                                 .
123.docx. .
 
1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证
1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证
1:1原版定制利物浦大学毕业证(Liverpool毕业证)成绩单学位证书留信学历认证
 
edited gordis ebook sixth edition david d.pdf
edited gordis ebook sixth edition david d.pdfedited gordis ebook sixth edition david d.pdf
edited gordis ebook sixth edition david d.pdf
 
Seven tools of quality control.slideshare
Seven tools of quality control.slideshareSeven tools of quality control.slideshare
Seven tools of quality control.slideshare
 
Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...
Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...
Abortion Clinic in Randfontein +27791653574 Randfontein WhatsApp Abortion Cli...
 
NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...
NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...
NO1 Best Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialist I...
 
一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理
 
如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证
如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证
如何办理(Dalhousie毕业证书)达尔豪斯大学毕业证成绩单留信学历认证
 
Formulas dax para power bI de microsoft.pdf
Formulas dax para power bI de microsoft.pdfFormulas dax para power bI de microsoft.pdf
Formulas dax para power bI de microsoft.pdf
 
社内勉強会資料  Mamba - A new era or ephemeral
社内勉強会資料   Mamba - A new era or ephemeral社内勉強会資料   Mamba - A new era or ephemeral
社内勉強会資料  Mamba - A new era or ephemeral
 
Sensing the Future: Anomaly Detection and Event Prediction in Sensor Networks
Sensing the Future: Anomaly Detection and Event Prediction in Sensor NetworksSensing the Future: Anomaly Detection and Event Prediction in Sensor Networks
Sensing the Future: Anomaly Detection and Event Prediction in Sensor Networks
 
如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证
如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证
如何办理英国卡迪夫大学毕业证(Cardiff毕业证书)成绩单留信学历认证
 
如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一
如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一
如何办理哥伦比亚大学毕业证(Columbia毕业证)成绩单原版一比一
 
Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...
Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...
Identify Rules that Predict Patient’s Heart Disease - An Application of Decis...
 
一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理
一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理
一比一原版加利福尼亚大学尔湾分校毕业证成绩单如何办理
 
NOAM AAUG Adobe Summit 2024: Summit Slam Dunks
NOAM AAUG Adobe Summit 2024: Summit Slam DunksNOAM AAUG Adobe Summit 2024: Summit Slam Dunks
NOAM AAUG Adobe Summit 2024: Summit Slam Dunks
 
1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证
1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证
1:1原版定制伦敦政治经济学院毕业证(LSE毕业证)成绩单学位证书留信学历认证
 
What is Insertion Sort. Its basic information
What is Insertion Sort. Its basic informationWhat is Insertion Sort. Its basic information
What is Insertion Sort. Its basic information
 

Data Structures in Python.pptx

  • 2. Data Structure  What is Data Structure?  Organizing, managing and storing data is important as it enables easier access and efficient modifications. Data Structures allows you to organize your data in such a way that enables you to store collections of data, relate them and perform operations on them accordingly.  Philosophy “Clever” ways to organize information in order to enable efficient computation
  • 3. Goals  what the tools are for storing and processing common data types  which tools are appropriate for which need  So that make good design choices as a programmer  Another Goal is it must be rich in structure to reflect the actual relationship of data in real world .The structure should be simple enough for efficient processing of data .
  • 5.
  • 6. Built-in Data Structure  Understand Data  Understand the data according to its Nature.  Map the data with available structure.  choosing the right data structure for your data
  • 7. Three W’s Why we are using data? What we are going to do with the data? Where we are sending data i.e location or container?
  • 8. Python’s Data structure Data Structure Built-in Data Structure List Tuples User Defined Data Structure Dictionary Set Hash Map Graph Linked List Tree Stack Queue
  • 10. Lists  This Data structure use for storing and accesing objects which belongs in a specific sequence.  Lists are used to store multiple items in a single variable  Lists in Python are linear containers used for storing data of various Data Types. The ability to store a variety of data is what makes Lists a very unique and vital Data Structure in Python.
  • 11. Examples  city_list=['Newyork','chicago', 'Los Angeles', 'Houston', 'Philadelphia', 'Dallas']  squares = [‘1’, ‘4, 9’, ’16’]  List with Mixed Data types  My_list = [‘1’ ,”Hello”, ‘3.5’]
  • 12. Example  data = [{"id": ("1", "2", "3"), "name": ("Dannie", "Williams"), "department": ("HR", "IT")}, {"id": ("4", "5", "6"), "name": ("jhon", "smith"), "department": ("HR", "IT")}, {"id": ("7", "8", "9"), "name": ("Allen", "polard"), "department": ("finance", "IT")}, {"id": ("10", "11", "12"), "name": ("Reema", "Ferguson"), "department": ("business", "IT")}, {"id": ("13", "14", "15"), "name": ("patrick", "Donald"), "department": ("business", "IT")}]
  • 14. Features of Lists  Lists are ordered.  Lists can contain any arbitrary objects.  List elements can be accessed by index.  Lists are mutable.  Lists are dynamic.
  • 15. Lists  Syntax  List_variables = [ val1,val2,val3…….]  My_list = [1,2,3]
  • 16. List Indices  my_list =[1,2,3,4,5,6,7,8,9,10]
  • 17. List Methods  Append()  Count  Index()  Insert()  Pop()  Remove()  Reverse()  Sort()  Extend()  If you want to remember these methods (ASPIRER)