SlideShare a Scribd company logo
1 of 22
Download to read offline
+
Dr. Ramadan Babers
Faculty of Science - Helwan University
Spring – 2019
Python
LEC - 01
for
Biologists
https://www.linkedin.com/in/ramadan-babers-phd-78976345
+
Introduction
2
Outlines
 Introduction
 How a Program Works
 Compilers and Interpreters
 Ambiguity
 Grammar
 Derivation
3
1. Introduction
4
Different ways that people use computers.
In school,
Students use computers
for tasks such as
 writing papers,
 searching for articles,
 sending email, and
 participating in online
classes.
1. Introduction
5
Different ways that people use computers.
At work,
People use computers to
 analyze data,
 make presentations,
 conduct business
transactions,
 communicate with
customers,
 control machines and
 do many other things.
1. Introduction
6
Different ways that people use computers.
At home,
People use computers for
tasks such as
 paying bills,
 shopping online,
 communicating with
friends and family, and
 playing computer
games.
1. Introduction
7
Computers can do such a wide variety of
things because they can be programmed.
This means that computers are not designed
to do just one job, but to do any job that their
programs tell them to do.
A program is a set of instructions that a
computer follows to perform a task
2. How a ProgramWorks
8
CONCEPT:
 A computer’s CPU can
only understand
instructions that are
written in machine
language.
 Because people find it
very difficult to write
entire programs in
machine language, other
programming languages
have been invented.
2. How a ProgramWorks
9
 CPU only understands
machine language, it is
difficult for people to
write programs in
machine language.
 For this reason,
assembly language was
created as an
alternative to machine
language.
2. How a ProgramWorks
10
 Assembly language programs cannot be executed
by the CPU, however.
 The CPU only understands machine language,so
a special program known as an assembler is used
to translate an assembly language program to a
machine language program.
3. Compilers and Interpreters
11
 Because the CPU understands only machine
language instructions, programs that are written
in a high-level language must be translated into
machine language.
 Depending on the language that a program has
been written in, the programmer will use either a
compiler or an interpreter to make the translation.
3.1 Compiler
12
3.2 Interpreters
13
The Python language uses an interpreter, which is a program that both
translates and executes the instructions in a high-level language
program. As the interpreter reads each individual instruction in the
program, it converts it to machine language instructions and then
immediately executes them.
3.3 Compiling and interpreting
14
 Many languages require
you to compile (translate)
your program into a form
that the machine
understands.
 Python is instead directly
interpreted into machine
instructions.
compile execute
outputsource code
Hello.java
byte code
Hello.class
interpret
outputsource code
Hello.py
4. Ambiguity
15
 Why Do We Need
Programming
Language
 Can we use natural
languages like
English?
4. Ambiguity (Quiz)
16
 Would you rather be paid $100 weekly or
biweekly?
o Prefer to be paid $100 weekly.
o Prefer to be paid $100 biweekly.
o It depends.
o Prefer not to be paid at all.
4. Ambiguity (Quiz)
17
4. Ambiguity (Quiz)
18
 Would you rather be paid $100 weekly or
biweekly?
o Prefer to be paid $100 weekly.
o Prefer to be paid $100 biweekly.
o It depends.
o Prefer not to be paid at all.
Different people understand different ways
5. Grammar
19
Noun example: I / Python
Verb example: eat / like
Noun Verb
Sentence Subject Verb Object
Noun Noun
6. Derivation
20
Sentence Subject Verb Object
Subject
Object
Verb
Verb
Noun
Noun
Noun
Noun
like
eat
I
Python
Non-terminal
terminal
Noun cookies
6. Derivation
21
Sentence Subject Verb Object
Non-terminal
terminal
Noun
like Noun
Verb
I
Object
Python
Subject
Object
Verb
Verb
Noun
Noun
Noun
Noun
like
eat
I
Python
Derivation:
Starting from some non-terminals,
follow the roles to derive the
sequence of terminals
7. Quiz
22
Sentence Subject Verb Object
Which of these sentences can be produced from
the following grammar? Starting from Sentence
o Python eat cookies
o Python eat Python
o I like eat
o Eat python cookies

More Related Content

What's hot

What is Coding
What is CodingWhat is Coding
What is CodingRoboGarden
 
Introduction to coding and Python
Introduction to coding and PythonIntroduction to coding and Python
Introduction to coding and PythonHaris NP
 
TRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjar
TRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjarTRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjar
TRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjarDr. Shadia Banjar
 
Basic introduction to python
Basic introduction to pythonBasic introduction to python
Basic introduction to pythonpoonam bora
 
Adam Goucher I18n And L10n
Adam Goucher   I18n And L10nAdam Goucher   I18n And L10n
Adam Goucher I18n And L10nAdam Goucher
 
Myanmar fonts & unicode
Myanmar fonts & unicodeMyanmar fonts & unicode
Myanmar fonts & unicodeNgwe Tun
 
Programming in python
Programming in python Programming in python
Programming in python Priya Nayak
 
Rashed almulla 11 ab
Rashed almulla 11 abRashed almulla 11 ab
Rashed almulla 11 abrashedalm
 
Creating a compiler for your own language
Creating a compiler for your own languageCreating a compiler for your own language
Creating a compiler for your own languageAndrea Tino
 
IRJET - Analysis on Code-Mixed Data for Movie Reviews
IRJET - Analysis on Code-Mixed Data for Movie ReviewsIRJET - Analysis on Code-Mixed Data for Movie Reviews
IRJET - Analysis on Code-Mixed Data for Movie ReviewsIRJET Journal
 
python classes in thane
python classes in thanepython classes in thane
python classes in thanefaizrashid1995
 
English for Computer unit 3 Software
English for Computer unit 3 SoftwareEnglish for Computer unit 3 Software
English for Computer unit 3 Softwareanchalee khunseesook
 
Python certification course bengalore
Python certification course bengalorePython certification course bengalore
Python certification course bengaloreavinashapponix
 

What's hot (20)

INTRODUCTIONS OF HTML
INTRODUCTIONS OF HTMLINTRODUCTIONS OF HTML
INTRODUCTIONS OF HTML
 
Python Glimpse
Python  Glimpse Python  Glimpse
Python Glimpse
 
Python
PythonPython
Python
 
Career in python
Career in pythonCareer in python
Career in python
 
What is Coding
What is CodingWhat is Coding
What is Coding
 
Introduction to coding and Python
Introduction to coding and PythonIntroduction to coding and Python
Introduction to coding and Python
 
TRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjar
TRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjarTRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjar
TRANSLATOR'S TOOLS, by Dr. Shadia Y. BAnjar
 
Basic introduction to python
Basic introduction to pythonBasic introduction to python
Basic introduction to python
 
Cs2 Ch1
Cs2 Ch1Cs2 Ch1
Cs2 Ch1
 
Adam Goucher I18n And L10n
Adam Goucher   I18n And L10nAdam Goucher   I18n And L10n
Adam Goucher I18n And L10n
 
Myanmar fonts & unicode
Myanmar fonts & unicodeMyanmar fonts & unicode
Myanmar fonts & unicode
 
Programming in python
Programming in python Programming in python
Programming in python
 
Rashed almulla 11 ab
Rashed almulla 11 abRashed almulla 11 ab
Rashed almulla 11 ab
 
Python language
Python languagePython language
Python language
 
Creating a compiler for your own language
Creating a compiler for your own languageCreating a compiler for your own language
Creating a compiler for your own language
 
IRJET - Analysis on Code-Mixed Data for Movie Reviews
IRJET - Analysis on Code-Mixed Data for Movie ReviewsIRJET - Analysis on Code-Mixed Data for Movie Reviews
IRJET - Analysis on Code-Mixed Data for Movie Reviews
 
python classes in thane
python classes in thanepython classes in thane
python classes in thane
 
1 cover page
1 cover page1 cover page
1 cover page
 
English for Computer unit 3 Software
English for Computer unit 3 SoftwareEnglish for Computer unit 3 Software
English for Computer unit 3 Software
 
Python certification course bengalore
Python certification course bengalorePython certification course bengalore
Python certification course bengalore
 

Similar to Python lec 1001_for_biologists

Python Intro Slides for Students CSC-148 Chapter 1
Python Intro Slides for Students CSC-148  Chapter 1Python Intro Slides for Students CSC-148  Chapter 1
Python Intro Slides for Students CSC-148 Chapter 1Raza Ul Mustafa
 
Specification Of The Programming Language Of Java
Specification Of The Programming Language Of JavaSpecification Of The Programming Language Of Java
Specification Of The Programming Language Of JavaKim Moore
 
Language processing system.pdf
Language processing system.pdfLanguage processing system.pdf
Language processing system.pdfRakibRahman19
 
Is Python a Programming language or Scripting Language.pdf
Is Python a Programming language or Scripting Language.pdfIs Python a Programming language or Scripting Language.pdf
Is Python a Programming language or Scripting Language.pdfKajal Digital
 
Is Python a Programming language or Scripting Language_.pdf
Is Python a Programming language or Scripting Language_.pdfIs Python a Programming language or Scripting Language_.pdf
Is Python a Programming language or Scripting Language_.pdfKajal Digital
 
Python Programming and ApplicationsUnit-1.docx
Python Programming and ApplicationsUnit-1.docxPython Programming and ApplicationsUnit-1.docx
Python Programming and ApplicationsUnit-1.docxManohar k
 
COMPUTER PROGRAMMING 10 WEEK 1.pptx
COMPUTER PROGRAMMING 10 WEEK 1.pptxCOMPUTER PROGRAMMING 10 WEEK 1.pptx
COMPUTER PROGRAMMING 10 WEEK 1.pptxNealFarias
 
1. Introduction Original - To Print
1. Introduction Original - To Print1. Introduction Original - To Print
1. Introduction Original - To PrintChinthaka Fernando
 
IRJET- Python: Simple though an Important Programming Language
IRJET- Python: Simple though an Important Programming LanguageIRJET- Python: Simple though an Important Programming Language
IRJET- Python: Simple though an Important Programming LanguageIRJET Journal
 
Introduction to python
Introduction to pythonIntroduction to python
Introduction to pythonJaya Kumari
 
notes on Programming fundamentals
notes on Programming fundamentals notes on Programming fundamentals
notes on Programming fundamentals ArghodeepPaul
 
C, C++, Java, Python, PHP, JavaScript and Linux For Beginners
C, C++, Java, Python, PHP, JavaScript and Linux For BeginnersC, C++, Java, Python, PHP, JavaScript and Linux For Beginners
C, C++, Java, Python, PHP, JavaScript and Linux For BeginnersManjunath.R -
 
Python Programming Course
Python Programming CoursePython Programming Course
Python Programming Courseiseestech
 
Python Online Training
Python Online TrainingPython Online Training
Python Online Trainingqts info
 
Basic Python Introduction Lecture 1.pptx
Basic Python Introduction Lecture 1.pptxBasic Python Introduction Lecture 1.pptx
Basic Python Introduction Lecture 1.pptxAditya Patel
 

Similar to Python lec 1001_for_biologists (20)

Python Intro Slides for Students CSC-148 Chapter 1
Python Intro Slides for Students CSC-148  Chapter 1Python Intro Slides for Students CSC-148  Chapter 1
Python Intro Slides for Students CSC-148 Chapter 1
 
Computer programming
Computer programmingComputer programming
Computer programming
 
Specification Of The Programming Language Of Java
Specification Of The Programming Language Of JavaSpecification Of The Programming Language Of Java
Specification Of The Programming Language Of Java
 
Language processing system.pdf
Language processing system.pdfLanguage processing system.pdf
Language processing system.pdf
 
Programming
ProgrammingProgramming
Programming
 
Is Python a Programming language or Scripting Language.pdf
Is Python a Programming language or Scripting Language.pdfIs Python a Programming language or Scripting Language.pdf
Is Python a Programming language or Scripting Language.pdf
 
Is Python a Programming language or Scripting Language_.pdf
Is Python a Programming language or Scripting Language_.pdfIs Python a Programming language or Scripting Language_.pdf
Is Python a Programming language or Scripting Language_.pdf
 
Python Programming and ApplicationsUnit-1.docx
Python Programming and ApplicationsUnit-1.docxPython Programming and ApplicationsUnit-1.docx
Python Programming and ApplicationsUnit-1.docx
 
COMPUTER PROGRAMMING 10 WEEK 1.pptx
COMPUTER PROGRAMMING 10 WEEK 1.pptxCOMPUTER PROGRAMMING 10 WEEK 1.pptx
COMPUTER PROGRAMMING 10 WEEK 1.pptx
 
Introduction to programming languages part 1
Introduction to programming languages   part 1Introduction to programming languages   part 1
Introduction to programming languages part 1
 
1. Introduction Original - To Print
1. Introduction Original - To Print1. Introduction Original - To Print
1. Introduction Original - To Print
 
IRJET- Python: Simple though an Important Programming Language
IRJET- Python: Simple though an Important Programming LanguageIRJET- Python: Simple though an Important Programming Language
IRJET- Python: Simple though an Important Programming Language
 
Introduction to python
Introduction to pythonIntroduction to python
Introduction to python
 
notes on Programming fundamentals
notes on Programming fundamentals notes on Programming fundamentals
notes on Programming fundamentals
 
C, C++, Java, Python, PHP, JavaScript and Linux For Beginners
C, C++, Java, Python, PHP, JavaScript and Linux For BeginnersC, C++, Java, Python, PHP, JavaScript and Linux For Beginners
C, C++, Java, Python, PHP, JavaScript and Linux For Beginners
 
C++ publish copy
C++ publish   copyC++ publish   copy
C++ publish copy
 
Python Programming Course
Python Programming CoursePython Programming Course
Python Programming Course
 
Python Online Training
Python Online TrainingPython Online Training
Python Online Training
 
Basic Python Introduction Lecture 1.pptx
Basic Python Introduction Lecture 1.pptxBasic Python Introduction Lecture 1.pptx
Basic Python Introduction Lecture 1.pptx
 
lecture 4
 lecture 4 lecture 4
lecture 4
 

More from Ramadan Babers, PhD

Part10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysisPart10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysisRamadan Babers, PhD
 
Part09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratioPart09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratioRamadan Babers, PhD
 
Part08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratioPart08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratioRamadan Babers, PhD
 
Part07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratioPart07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratioRamadan Babers, PhD
 
Part06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratioPart06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratioRamadan Babers, PhD
 
Part05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentationPart05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentationRamadan Babers, PhD
 
Part04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentationPart04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentationRamadan Babers, PhD
 
Part03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentationPart03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentationRamadan Babers, PhD
 
Part02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentationPart02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentationRamadan Babers, PhD
 
Part01 finance investment_basics_presentation
Part01 finance investment_basics_presentationPart01 finance investment_basics_presentation
Part01 finance investment_basics_presentationRamadan Babers, PhD
 
Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0Ramadan Babers, PhD
 
Classification using decision tree in detail
Classification using decision tree in detailClassification using decision tree in detail
Classification using decision tree in detailRamadan Babers, PhD
 

More from Ramadan Babers, PhD (20)

Part10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysisPart10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysis
 
Part09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratioPart09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratio
 
Part08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratioPart08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratio
 
Part07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratioPart07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratio
 
Part06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratioPart06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratio
 
Part05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentationPart05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentation
 
Part04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentationPart04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentation
 
Part03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentationPart03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentation
 
Part02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentationPart02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentation
 
Part01 finance investment_basics_presentation
Part01 finance investment_basics_presentationPart01 finance investment_basics_presentation
Part01 finance investment_basics_presentation
 
Strategic Management part_03_03
Strategic Management part_03_03Strategic Management part_03_03
Strategic Management part_03_03
 
Strategic Management part_02_03
Strategic Management part_02_03Strategic Management part_02_03
Strategic Management part_02_03
 
Strategic Management part_01_03
Strategic Management part_01_03Strategic Management part_01_03
Strategic Management part_01_03
 
Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0
 
Classification using decision tree in detail
Classification using decision tree in detailClassification using decision tree in detail
Classification using decision tree in detail
 
Customer Experience (CX)
Customer Experience (CX)Customer Experience (CX)
Customer Experience (CX)
 
Python lec 1004_ch02_excercies
Python lec 1004_ch02_excerciesPython lec 1004_ch02_excercies
Python lec 1004_ch02_excercies
 
Python lec 1003_for_biologists
Python lec 1003_for_biologistsPython lec 1003_for_biologists
Python lec 1003_for_biologists
 
Db lec 08_new
Db lec 08_newDb lec 08_new
Db lec 08_new
 
Db lec 07_new
Db lec 07_newDb lec 07_new
Db lec 07_new
 

Recently uploaded

Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaVirag Sontakke
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementmkooblal
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfMahmoud M. Sallam
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupJonathanParaisoCruz
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfUjwalaBharambe
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,Virag Sontakke
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...jaredbarbolino94
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentInMediaRes1
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 

Recently uploaded (20)

Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of India
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of management
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdf
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized Group
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media Component
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 

Python lec 1001_for_biologists

  • 1. + Dr. Ramadan Babers Faculty of Science - Helwan University Spring – 2019 Python LEC - 01 for Biologists https://www.linkedin.com/in/ramadan-babers-phd-78976345
  • 3. Outlines  Introduction  How a Program Works  Compilers and Interpreters  Ambiguity  Grammar  Derivation 3
  • 4. 1. Introduction 4 Different ways that people use computers. In school, Students use computers for tasks such as  writing papers,  searching for articles,  sending email, and  participating in online classes.
  • 5. 1. Introduction 5 Different ways that people use computers. At work, People use computers to  analyze data,  make presentations,  conduct business transactions,  communicate with customers,  control machines and  do many other things.
  • 6. 1. Introduction 6 Different ways that people use computers. At home, People use computers for tasks such as  paying bills,  shopping online,  communicating with friends and family, and  playing computer games.
  • 7. 1. Introduction 7 Computers can do such a wide variety of things because they can be programmed. This means that computers are not designed to do just one job, but to do any job that their programs tell them to do. A program is a set of instructions that a computer follows to perform a task
  • 8. 2. How a ProgramWorks 8 CONCEPT:  A computer’s CPU can only understand instructions that are written in machine language.  Because people find it very difficult to write entire programs in machine language, other programming languages have been invented.
  • 9. 2. How a ProgramWorks 9  CPU only understands machine language, it is difficult for people to write programs in machine language.  For this reason, assembly language was created as an alternative to machine language.
  • 10. 2. How a ProgramWorks 10  Assembly language programs cannot be executed by the CPU, however.  The CPU only understands machine language,so a special program known as an assembler is used to translate an assembly language program to a machine language program.
  • 11. 3. Compilers and Interpreters 11  Because the CPU understands only machine language instructions, programs that are written in a high-level language must be translated into machine language.  Depending on the language that a program has been written in, the programmer will use either a compiler or an interpreter to make the translation.
  • 13. 3.2 Interpreters 13 The Python language uses an interpreter, which is a program that both translates and executes the instructions in a high-level language program. As the interpreter reads each individual instruction in the program, it converts it to machine language instructions and then immediately executes them.
  • 14. 3.3 Compiling and interpreting 14  Many languages require you to compile (translate) your program into a form that the machine understands.  Python is instead directly interpreted into machine instructions. compile execute outputsource code Hello.java byte code Hello.class interpret outputsource code Hello.py
  • 15. 4. Ambiguity 15  Why Do We Need Programming Language  Can we use natural languages like English?
  • 16. 4. Ambiguity (Quiz) 16  Would you rather be paid $100 weekly or biweekly? o Prefer to be paid $100 weekly. o Prefer to be paid $100 biweekly. o It depends. o Prefer not to be paid at all.
  • 18. 4. Ambiguity (Quiz) 18  Would you rather be paid $100 weekly or biweekly? o Prefer to be paid $100 weekly. o Prefer to be paid $100 biweekly. o It depends. o Prefer not to be paid at all. Different people understand different ways
  • 19. 5. Grammar 19 Noun example: I / Python Verb example: eat / like Noun Verb Sentence Subject Verb Object Noun Noun
  • 20. 6. Derivation 20 Sentence Subject Verb Object Subject Object Verb Verb Noun Noun Noun Noun like eat I Python Non-terminal terminal Noun cookies
  • 21. 6. Derivation 21 Sentence Subject Verb Object Non-terminal terminal Noun like Noun Verb I Object Python Subject Object Verb Verb Noun Noun Noun Noun like eat I Python Derivation: Starting from some non-terminals, follow the roles to derive the sequence of terminals
  • 22. 7. Quiz 22 Sentence Subject Verb Object Which of these sentences can be produced from the following grammar? Starting from Sentence o Python eat cookies o Python eat Python o I like eat o Eat python cookies