SlideShare a Scribd company logo
5
Most read
6
Most read
7
Most read
Subject: Compiler Design
Presentation On Relationship Among Tokens, Pattern & Lexemes
Submitted To :
Mr. Gaurav Dubey
(Asst. Prof. , Department of
Computer Science & Engineering)
Submitted By :
Bharat Rathore
0905CS191062
Activity - 1
OUTLINES
• Token
• Lexeme
• Pattern
• Relationship
Tokens
Tokens : A token is sequence of characters that can be treated
as a unit/single logical entity.
Examples
• Keywords
Examples : for, while, if etc.
• Identifier
Examples : Variable name, function name, etc.
• Operators
Examples : '+', '++', '-' etc.
• Separators
Examples : ',' ';' etc.
Example on Tokens
int a = 10 ;
Keyword
Constant
Identifier
Separator
Operator
Lexeme
It is a sequence of characters in the source program that is matched
by the pattern for a token.
Example : “float”, “=“, “223”, “;”
Pattern
Pattern is a rule describing all those lexemes that can represent a
particular token in a source language.
Relationship
Relationship Between Token, Pattern & Lexeme
Relationship Among Token, Lexeme & Pattern

More Related Content

PPTX
Lex & yacc
PPT
Lecture 1 - Lexical Analysis.ppt
PPTX
Lexical analyzer
PPT
1.Role lexical Analyzer
PDF
Lexical Analysis - Compiler design
PPT
Compiler Design Basics
PPTX
A Role of Lexical Analyzer
Lex & yacc
Lecture 1 - Lexical Analysis.ppt
Lexical analyzer
1.Role lexical Analyzer
Lexical Analysis - Compiler design
Compiler Design Basics
A Role of Lexical Analyzer

What's hot (20)

PPTX
Syntax Analysis in Compiler Design
PPTX
Recognition-of-tokens
PPTX
Input-Buffering
PPTX
serializability in dbms
PPTX
Compiler Chapter 1
PDF
Code optimization in compiler design
PPTX
Congestion control
PPTX
Top down parsing
PPTX
Peephole optimization techniques in compiler design
PDF
OS - Process Concepts
PPT
Kleene's theorem
PPTX
Loop optimization
PPTX
Network software
PPTX
Cocomo model
PPTX
Specification-of-tokens
PPTX
INTER PROCESS COMMUNICATION (IPC).pptx
PPTX
Analysis and Design of Algorithms
PPT
Intermediate code generation (Compiler Design)
PPTX
Finite automata-for-lexical-analysis
PPTX
Structure of the page table
Syntax Analysis in Compiler Design
Recognition-of-tokens
Input-Buffering
serializability in dbms
Compiler Chapter 1
Code optimization in compiler design
Congestion control
Top down parsing
Peephole optimization techniques in compiler design
OS - Process Concepts
Kleene's theorem
Loop optimization
Network software
Cocomo model
Specification-of-tokens
INTER PROCESS COMMUNICATION (IPC).pptx
Analysis and Design of Algorithms
Intermediate code generation (Compiler Design)
Finite automata-for-lexical-analysis
Structure of the page table
Ad

Similar to Relationship Among Token, Lexeme & Pattern (20)

PPTX
Compiler Design
TXT
tokens patterns and lexemes
PPTX
Lexical Analyser PPTs for Third Lease Computer Sc. and Engineering
PDF
Lexical analysis Compiler design pdf to read
PDF
Lexical analysis compiler design to read and study
PPTX
Role-of-lexical-analysis
PPT
Lecturer-05 lex anylser (1).pptrjyghsgst
PPT
Chapter-2-lexical-analyser and its property lecture note.ppt
PPT
52232.-Compiler-Design-Lexical-Analysis.ppt
PDF
Compiler lec 8
PDF
Assignment4
PPTX
Lex programming
PPT
Compiler Designs
PDF
Bishwadeep Bose_Compiler Design.pdf made by student
PPT
CS540-2-lecture2 Lexical analyser of .ppt
PDF
Chapter2CDpdf__2021_11_26_09_19_08.pdf
PDF
3a. Context Free Grammar.pdf
PPTX
04LexicalAnalysissnsnjmsjsjmsbdjjdnd.pptx
PDF
Lexical Analysis.pdf
Compiler Design
tokens patterns and lexemes
Lexical Analyser PPTs for Third Lease Computer Sc. and Engineering
Lexical analysis Compiler design pdf to read
Lexical analysis compiler design to read and study
Role-of-lexical-analysis
Lecturer-05 lex anylser (1).pptrjyghsgst
Chapter-2-lexical-analyser and its property lecture note.ppt
52232.-Compiler-Design-Lexical-Analysis.ppt
Compiler lec 8
Assignment4
Lex programming
Compiler Designs
Bishwadeep Bose_Compiler Design.pdf made by student
CS540-2-lecture2 Lexical analyser of .ppt
Chapter2CDpdf__2021_11_26_09_19_08.pdf
3a. Context Free Grammar.pdf
04LexicalAnalysissnsnjmsjsjmsbdjjdnd.pptx
Lexical Analysis.pdf
Ad

Recently uploaded (20)

PPTX
Foundation to blockchain - A guide to Blockchain Tech
PPTX
Lesson 3_Tessellation.pptx finite Mathematics
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
Welding lecture in detail for understanding
PPTX
bas. eng. economics group 4 presentation 1.pptx
PPTX
Construction Project Organization Group 2.pptx
PDF
Operating System & Kernel Study Guide-1 - converted.pdf
PPT
Project quality management in manufacturing
PPTX
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
PPTX
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PDF
Structs to JSON How Go Powers REST APIs.pdf
PDF
Arduino robotics embedded978-1-4302-3184-4.pdf
PPTX
additive manufacturing of ss316l using mig welding
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
DOCX
573137875-Attendance-Management-System-original
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
UNIT 4 Total Quality Management .pptx
Foundation to blockchain - A guide to Blockchain Tech
Lesson 3_Tessellation.pptx finite Mathematics
Internet of Things (IOT) - A guide to understanding
Welding lecture in detail for understanding
bas. eng. economics group 4 presentation 1.pptx
Construction Project Organization Group 2.pptx
Operating System & Kernel Study Guide-1 - converted.pdf
Project quality management in manufacturing
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
Structs to JSON How Go Powers REST APIs.pdf
Arduino robotics embedded978-1-4302-3184-4.pdf
additive manufacturing of ss316l using mig welding
UNIT-1 - COAL BASED THERMAL POWER PLANTS
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
573137875-Attendance-Management-System-original
Model Code of Practice - Construction Work - 21102022 .pdf
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
UNIT 4 Total Quality Management .pptx

Relationship Among Token, Lexeme & Pattern

  • 1. Subject: Compiler Design Presentation On Relationship Among Tokens, Pattern & Lexemes Submitted To : Mr. Gaurav Dubey (Asst. Prof. , Department of Computer Science & Engineering) Submitted By : Bharat Rathore 0905CS191062 Activity - 1
  • 2. OUTLINES • Token • Lexeme • Pattern • Relationship
  • 3. Tokens Tokens : A token is sequence of characters that can be treated as a unit/single logical entity. Examples • Keywords Examples : for, while, if etc. • Identifier Examples : Variable name, function name, etc. • Operators Examples : '+', '++', '-' etc. • Separators Examples : ',' ';' etc.
  • 4. Example on Tokens int a = 10 ; Keyword Constant Identifier Separator Operator
  • 5. Lexeme It is a sequence of characters in the source program that is matched by the pattern for a token. Example : “float”, “=“, “223”, “;”
  • 6. Pattern Pattern is a rule describing all those lexemes that can represent a particular token in a source language.