Write a program to accept a character & display its
corrosponding ASCII value & vice versa?
Answer Posted / pawankumar
#include<stdio.h>
#include<conio.h>
void main()
{
clrscr();
int x;
char y;
printf("enter the number");
scanf("%d",&x);
printf("enter the char");
scanf(" %c",&y);
if(sizeof(x)==4)
{
printf("the equivalent char for given
integer is %c ",x);
}
if(sizeof(y)==1)
{
printf("the equivalent integer for given
char is %d ",y);
}
}
| Is This Answer Correct ? | 8 Yes | 15 No |
Post New Answer View All Answers
Explain the difference between call by value and call by reference in c language?
Differentiate between functions getch() and getche().
hi, which software companys will take,if d candidate's % is jst 55%?
Linked list is a Linear or non linear explain if linear how it working as a non linear data structures
What is the use of pragma in embedded c?
What is pointer to pointer in c language?
What is the use of f in c?
formula to convert 2500mmh2o into m3/hr
How can I do peek and poke in c?
Differentiate between the expression “++a” and “a++”?
What does sizeof return c?
what are non standard function in c
What is a 'null pointer assignment' error? Explain what are bus errors, memory faults, and core dumps?
What are pointers? Why are they used?
What is volatile c?