#include <stdio.h>
int main()
{
if ("X" <"x")
printf("X smaller than x
");
}
my question is whats the mistake in this program? find it and please tell me..
Answer Posted / sandeep
Friend
In c if we write string constants like "Hi" "Hello world"
etc,it will be just a poiinter unless u prints it.
So if pointer pointing "X" is greater "if will not be executed"
else if pointer pointing "x" is greater "if will be executed"
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
The program will first compute the tax you owe based on your income. User is prompted to enter income. Program will compute the total amount of tax owed based on the following: Income Tax 0 - $45,000 = 0.15 x income $45,001 - $90,000 = 6750 + 0.20 x (income – 45000) $90,001 - $140,000 = 15750 + 0.26 x (income – 90000) $140,001 - $200,000 = 28750 + 0.29 x (income – 140000) Greater than $200,000 = 46150 + 0.33 x (income – 200000) Dollar amounts should be in dollars and cents (float point numbers with two decimals shown). Tax is displayed on the screen.
Write a program to check prime number in c programming?
all c language question
When c language was developed?
What is an lvalue?
How do you generate random numbers in C?
What is the correct code to have following output in c using nested for loop?
When is a void pointer used?
In C programming, how do you insert quote characters (‘ and “) into the output screen?
what is the height of tree if leaf node is at level 3. please explain
What is use of bit field?
Is the exit() function same as the return statement? Explain.
Do string constants represent numerical values?
Can a void pointer point to a function?
Write a program to print “hello world” without using semicolon?