I'm having trouble with coming up with the correct code.
Thank You!!
The assignment was to write a program using string functions
that accepts a price of an item and displays its coded value. The base of the keys:

X C O M P U T E R S
0 1 2 3 4 5 6 7 8 9

Sample I/O Dialogue:

Enter Price: 489.50
Coded Value: PRS.UX


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More C C++ Errors Interview Questions

#include"stdio.h" #include"conio.h" void main() { int a; printf("\n enter a number:"); scanf("%c\n"); getch(); }

12 Answers   HCL,


errors are known as?

3 Answers   EX, State Bank Of India SBI,


Write a c-programe that input one number of four digits and find digits sum?

2 Answers  


Given an int variable n that has been initialized to a positive value and, in addition, int variables k and total that have already been declared, use a do...while loop to compute the sum of the cubes of the first n whole numbers, and store this value in total . Thus if n equals 4, your code should put 1*1*1 + 2*2*2 + 3*3*3 + 4*4*4 into total . Use no variables other than n , k , and total .

3 Answers  


what is macro in c? Difference between single linked list & double linked list what is fifo & lifo? what is stack & queue?

2 Answers   TCS,






Display this kind of output on screen. 1 0 1 1 0 1 3. Display this kind of output on screen. 1 1 0 1 0 1 4. Display this kind of output on screen. 1 1 0 1 0 1 5.Display this kind of output on screen. 1 2 3 4 5 6 7 8 9 10

1 Answers  


printy(a=3,a=2)

3 Answers  


Find the error (2.5*2=5) (a) X=y=z=0.5,2.0-5.75 (b) s=15;

3 Answers  


What are the different types of errors in C and when they occur?

4 Answers  


which typw of errors ? & how to solve it ?

0 Answers  


void main() { int i=7; printf("N= %*d",i,i); }

6 Answers   HCL,


loop1: { x=i<n?(i++):0; printf("%d",i); exit(x); continue; } Error- misplaced continue. Doubt-1.will the exit(x) be executed for all values of x 2.will this statement go out of the program.

5 Answers   CMC,


Categories