Sunday, May 19, 2024
HomeC Programmingwhat are key phrases in c

what are key phrases in c


What’s Key phrase in C Programming?

In C Programming,Key phrases are nothing however reserved phrase which has particular that means assigned to it. Key phrases are also called Reserved phrase.Key phrases are a part of the syntax and so they can’t be used as an identifier.In C,We’ve complete 32 Key phrases.As C is Case Delicate Language all of the key phrases should be outlined in decrease case.Let’s Perceive Key phrase With an instance.

int rollno;

In above Eg  now we have declared one variable of sort int.On this Instance int is key phrase or Reserved phrase,In above eg we can’t use Int as an alternative of int,As a result of now we have already seen all of the key phrases should be outlined in decrease case.

What’s Case Sensitivity in C Programming?

In Pc Programming,Case Delicate defines each UpperCase and LowerCase letter  have totally different that means.For Eg Whats up and whats up are totally different from one another.Let’s perceive with an instance

int Age=12;

int age=23;



In above eg,We’ve declared two variable of similar identify.However the reminiscence location and worth of each variable can be totally different as a result of One Variable is outlined  as UpperCase and different as LowerCase.I hope Now you bought it what’s Case Sensitivity in Programming.You probably have nonetheless any doubt then be at liberty to ask on Remark.

Primary Utilization of Key phrases in C Programming:


return – This key phrase is used for returning a price from a operate.When this key phrase is encountered  inside a operate the execution  will go to the place from the place this operate was referred to as.All of the  assertion after this key phrase won’t be executed,Subsequently it is strongly recommended to make use of return key phrase as a final assertion of the  operate.


goto – Used for redirecting the movement of execution from one place to a different.This key phrase is used with specific label.That is additionally Recognized Branching or Bounce Assertion.Let’s Perceive With an instance.


goto a;





printf(“Whats up”);


In above eg the management  will straight soar to a label and it’ll print Whats up and it’ll ignore Bye Assertion.


struct, typedef  – Each of those key phrases utilized in buildings (Grouping of knowledge varieties in a single file).Struct key phrase is used for creating person outlined knowledge sort.We are going to study extra about construction in additional class.


union – It’s a assortment of variables, which shares the identical reminiscence location and reminiscence storage.It’s much like struct key phrase.


enum – It’s use to outline Set of constants.  


for, whereas, do – forms of loop buildings in C.We are going to study extra about this in additional class.

proceed – It’s typically used with for, whereas and
dowhile loops, whereas execution of a program when compiler encounter this key phrase it merely performs the following iteration of the loop and skip the remainder of the instruction of the present iteration.  


auto, signed, const, extern, register, unsigned – This key phrases are used to outline the variable on totally different bases.For eg auto,extern and register are storage class.signed and unsigned are used to outline variable on the idea of signal(+ve,-ve) of a quantity.const key phrase is used to outline fixed variable.


int, float, char, double, lengthy – These are the info varieties and used throughout variable declaration.Click on right here to Study extra about knowledge sort.


break – It’s utilized in Loop and change case assertion.In loop,when the compiler encounter this key phrase it merely break the present loop and management will come exterior of the loop.In Change Case,this key phrase is used on the finish of every case as a result of if we won’t use it then all of the case after the matched case can be executed till subsequent break assertion is encounter.

if, else, change, case, default – Used for determination management programming construction.We are going to study extra about this in additional class.

void – One of many return sort.void key phrase specifies that the operate doesn’t return a price.


unstable :The unstable key phrase
is meant to forestall the compiler from making use of any optimizations on
objects that may change in methods that can not be decided by the

sizeof – It’s used to know the scale.It returns the measurement of a variable.When sizeof() is used with the info varieties, it merely returns the quantity of reminiscence allotted to that knowledge sort.


brief:The brief key phrase is sort  modifier that alter the that means of base knowledge sort by decreasing the scale of reminiscence allotted by variable.

static:In C Programming,static key phrase can be utilized with each variable and performance i.e we will declare variable as static and static operate.The principle distinction between non-static variable and static variable is static variable acts as a worldwide variable and is shared amongst all of the objects of the category whereas a non-static variables are particular to occasion object wherein they’re created.The distinction between static operate and non-static operate is Static means you
should not have to instantiate (declare an object reference). That’s, you
can merely use the tactic,whereas the reply could also be
the identical, the way in which you referred to as that technique/operate is totally different.


When you any have doubt,suggestion relating to this put up or web site then be at liberty to share with us.


You probably have realized one thing new from this put up then share this put up with your loved ones and


Glad Studying :)😎    





Please enter your comment!
Please enter your name here

Most Popular

Recent Comments