if we take a number as a char then can we manipulate(add,
subtract) on this number
Answers were Sorted based on User's Feedback
Answer / aravind
yes.For example
#include<stdio.h>
int main()
{
int x,y;
x='A'+1;
y='B'-1;
printf("%d,%d\n",x,y);
}
It will add the Asci value of A and subtracts B, Than 62 or B will be ans for x and A or 61 will be ans for y.
| Is This Answer Correct ? | 8 Yes | 0 No |
Answer / deepak garg
#include<stdio.h>
int main()
{
int x,y;
x=1+'a';
y='b'-1;
printf("%d,%d\n",x,y);
}
| Is This Answer Correct ? | 1 Yes | 0 No |
who is the founder of c
19 Answers College School Exams Tests, HP,
Write the test cases for checking a variable having value in range -10.0 to +10.0?
What is typeof in c?
what value is returned to operating system after program execution?
Can you tell me how to check whether a linked list is circular?
i want to asked a question about c program the question is: create a c program that displays all prime numbers less than 500? using looping statement
Juxtapose the use of override with new. What is shadowing?
What are all different types of pointers in c?
in case any function return float value we must declare a) the function must be declared as 'float' in main() as well b) the function automatically returned float values c) function before declared 'float' keyword d) all the above
write a program whose output will be- 1 12 123 1234
Can you please explain the difference between exit() and _exit() function?
How do I access command-line arguments?