Write a program to accept a character & display its
corrosponding ASCII value & vice versa?

Answer Posted / sanjay malik

#include<stdio.h>
main()
{
char ch;
printf("ENTER A CHARACTER: ");
scanf("%c",&ch);
printf("THE ASCII CODE IS %d",ch);}

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What does s c mean in text?

630


What is structure padding and packing in c?

631


What is #define?

584


How can I swap two values without using a temporary?

625


Create a structure to specify data on students as given below: Roll number, Name, Department, Course, and Year of joining. Assume that there are not more than 450 students in the collage. (a) Write a function to print the names of all students who joined in the last 3 years. (b) Write a function to print the data of a student whose roll numbers are divisible by 4.

613






What is volatile, register definition in C

704


What is the purpose of macro in C language?

674


When should volatile modifier be used?

562


Explain the process of converting a Tree into a Binary Tree.

2117


What is the role of this pointer?

561


What is typedf?

676


What is the best style for code layout in c?

639


What is an array in c?

605


Explain the ternary tree?

613


How can I remove the trailing spaces from a string?

624