Write a C Programm..
we press 'a' , it shows the albhabetical number is 1, if we
press 'g' it shows the answer 7.. any can help me
Answer Posted / vignesh1988i
#include<stdio.h>
#include<conio.h>
void main()
{
char s;
printf("enter the character :");
scanf("%d",&s);
printf("\n here CAPITAL and SMALL letters are taken as same\n");
if(s>='A'&&s<='Z')
printf("\nthis is the %dth alphabet from first",s-'A');
else if(s>='a'&&s<='z')
printf("\nthis is the %dth alphabet from first",s-'a');
else
printf("\n INVALID ALPHABET");
getch();
}
thank u
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
What is variable initialization and why is it important?
please explain every phase in the "SDLC" in the dotnet.
How can I recover the file name given an open stream?
any C program contains only one function, it must be a) void () b) main () c) message () d) abc ()
What is break statement?
How can variables be characterized?
All technical questions
What does %c mean in c?
What is the use of a conditional inclusion statement in C?
in ‘C’ language for Matrix Multiplication fails” Introspect the causes for its failure and write down the possible reasons for its failure.
write a c program to find the largest and 2nd largest numbers from the given n numbers without using arrays
What is a macro, and explain how do you use it?
What is boolean in c?
Where is volatile variable stored?
hi, which software companys will take,if d candidate's % is jst 55%?