for example user gives input as " 20 or 20.0 or rs 20.0 or
20.00 or rs20 and so .. on " and the output should be
stored as " rs.20.00 " in a variable
Answers were Sorted based on User's Feedback
Answer / vignesh1988i
#include<stdio.h>
#include<conio.h>
void main()
{
float i;
printf("enter the value :");
scanf("%f",&i);
printf("the output is : %f",i);
getch();
}
thank u. please make ur question more clear
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / aditya
#include<stdio.h>
#include<conio.h>
void main()
{
string ss;
printf("enter the value :");
scanf("%s",&ss);
printf("the output is : %s",ss);
getch();
}
| Is This Answer Correct ? | 0 Yes | 0 No |
A banker has a seif with a cipher. Not to forget the cipher, he wants to write it coded as following: each digit to be replaced with the difference of 9 with the current digit. The banker chose a cipher. Decipher it knowing the cipher starts with a digit different than 9. I need to write a program that takes the cipher from the keyboard and prints the new cipher. I thought of the following: Take the input from the keyboard and put it into a string or an array. Go through the object with a for and for each digit other than the first, substract it from 9 and add it to another variable. Print the new variable. Theoretically I thought of it but I don't know much C. Could you give me any kind of hint, whether I am on the right track or not?
How can I rethow can I return a sequence of random numbers which dont repeat at all?
why do we use # in c-language?
What does a pointer variable always consist of?
What is a null pointer in c?
Why do we need volatile in c?
What is the value of y in the following code? x=7;y=0; if(x=6) y=7; else y=1;
What is RAM memory? and What is ROM?Who designed one is temparary and another is permanent?why they designed like that?By using far pointer which type data(whether hexadecimal)we can access?
Why is c called a structured programming language?
What is the description for syntax errors?
Which header file is used for clrscr?
Explain what would happen to x in this expression: x += 15; (assuming the value of x is 5)