Wednesday, March 27, 2013

Ques: What do you mean by token? Classify the c token?

Solution:


Token: We write a program with a programming language C.Then this program contains some words (a-z,0-9,........),some special words(#,%,.......),bracket,punctuation etc.Every each group is called token.



Classification of C token:

There are six types of token in C.


1.keywords......(do, if, auto,while,.....)

2.identifiers......(num, sum,......) 

3.constants.....(const pi=3.1416)

4.string constants....("bangladesh")

5.operators and expressions.....(a=b+c,....)

6.punctuators......(; , . , .........)

No comments:

Post a Comment