WAP to convert text into its ASCII Code and also write a
function to decode the text given?

Answers were Sorted based on User's Feedback



WAP to convert text into its ASCII Code and also write a function to decode the text given?..

Answer / harish solanki

#include<stdio.h>
#include<conio.h>
void main()
{
char c,d;
int a;
clrscr();
printf("enter character");
scanf("%c",&c);
a=c;
d=a;
printf("the ascii code is:%d",a);
printf("the character is:%c",d);
getch();
}

Is This Answer Correct ?    6 Yes 1 No

WAP to convert text into its ASCII Code and also write a function to decode the text given?..

Answer / shashank mahabdi

to convert it into ascii code just assign the entered
variable to a int(integer)variabe e.g.
int i=a
which on printing i will gie 64 as the o/p

Is This Answer Correct ?    1 Yes 6 No

Post New Answer

More C Interview Questions

How can this be legal c?

0 Answers  


Which function in C can be used to append a string to another string?

0 Answers  


Explain what is the advantage of a random access file?

0 Answers  


errors in computer programmes are called

1 Answers   NET,


char S; char S[6]= " HELLO"; printf("%s ",S[6]); output of the above program ? (0, ASCII 0, I,unpredictable)

7 Answers   Mascot,


can anyone please tell me wat is backlogs... i was looking for the job openings where i read this.. eligibility criteria minimum 70% in degree without backlogs. is that arrear.. if so is it standing arrear or history of arrears... please help me...

11 Answers   CTS, Indian Navy, L&T, Microsoft, SSB, TCE, TCS,


i=20,k=0; for(j=1;j<i;j=1+4*(i/j)) { k+=j<10?4:3; } printf("%d", k);

8 Answers   HCL,


Can you write the algorithm for Queue?

0 Answers   College School Exams Tests, TCS,


Is null valid for pointers to functions?

0 Answers  


Tell me with an example the self-referential structure?

0 Answers  


WHAT IS HIGH LEVEL LANGUAGE?

2 Answers  


What is key word in c language?

4 Answers   ABC,


Categories