C keyword and identifier




In this tutorial  you will learn about keywords and identifier of C programming  language  

What is keywords in C programming language 

Keywords are some reserved  words that C language use for denoting something specific.In C language  keywords written in lower case.C language has 32 keywords 

Keywords are predefined reserved words used in programming that have special meanings to the compiler.Keywords are part of the syntax and they cannot used as identifier

Character set of C
  • Character: it denoted any alphabet,digit or special symbol used to represent information.
  • Use: These characters can be combined to form variable,C use Constants.variable,operators,keyword,and expression as building blocks to form a basic C programming language.
  • Character set:The character set is the fundamental raw material of any language and they are used to represent information,Like natural language,compile. Language will also have well defined character set,which is useful to build the programs 

  • As every language contains a set of characters used to construct words, statements, etc., C language also has a set of characters which include alphabets, digits, and special symbols. C language supports a total of 256 characters.

  • Every C program contains statements. These statements are constructed using words and these words are constructed using characters from C character set. C language character set contains the following set of characters...

  1. Alphabets
  2. Digits
  3. Special Symbols
  • Alphabets
C programming language support all the alphabets from the english language 
  • Uppercase = ABC.............................XYZ
  • Lowercase =abc.................................Abc
Digital
C programming language support 0 to 9 digits
      Digits= 0123456789
Special symbol 



Identifier in C language
  • Identifier are name for  entities in C programme,such as variable, arrays,function ,structure  unions and labels.an identifier can be composed only of uppercase ,lowercase letters,underscore and digit but should start only with an alphabet or an underscore 
  • Identifier must be unique they are created to give a unique name to an entity to identify it during the execution of the programme

Rules for an Identifier
  • An Identifier can only have alphanumeric characters(a-z , A-Z , 0-9) and underscore( _ ).
  • The first character of an identifier can only contain alphabet(a-z , A-Z) or underscore ( _ ).
  • Identifiers are also case sensitive in C. For example name and Name are two different identifiers in C.












           



Comments

Popular posts from this blog

C language introduction

Variable in C language