Skip to main content

Command Palette

Search for a command to run...

Token in C Language

Published
1 min read

* Tokens are also known as lexical element

* The text of c/c++ program consist of token and white space

* The token is the smallest element of a c/c++ program that is meaning full to the complier

* Parser is a program whose job is to separate these tokens

Tokens

Parser recognizes these kinds of tokens

  • constants

  • Identifiers (variables ,functions...)

  • Keywords

  • Operators

  • Punctuations