Syntax :-
typedef Data type identifiar;
Ex:-
Typedef int Prasad;
Example:-
#include<stdio.h>
#include<conio.h>
void main()
{
typedef int a;
typedef float b;
typedef char c;
a i;
b j;
c k;
clrscr();
printf("enter a int value:");
scanf("%d",&i);
printf("enter a float value:");
scanf("%f",&j);
printf("enter a char value:");
scanf("%s",&k);
printf("the int value is:=%d",i);
printf("\nthe float value is:=%f",j);
printf("\nthe char value is:=%c",k);
getch();
}
|
Output:-
---------------------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------------------
>> Back to Notes of C-Language (Topic Wise)
---------------------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------------------
>> Back to Quiz of All Computer Courses
>> Back to Shortcuts of All Computer Courses
>> Back to Video Tutorials of All Computer Courses
>> Back to Abbreviations
>> Back to Shortcuts of All Computer Courses
>> Back to Video Tutorials of All Computer Courses
>> Back to Abbreviations
---------------------------------------------------------------------------------------------------------------
Post a Comment