void main()
{
char code[15], name[15], grade;
int student, A=0, B=0, C=0, F=0, y=1, x, i=0;
float midterm, final, total, quizm, assignment;
printf("\nEnter Subject...
Type: Posts; User: karipap
void main()
{
char code[15], name[15], grade;
int student, A=0, B=0, C=0, F=0, y=1, x, i=0;
float midterm, final, total, quizm, assignment;
printf("\nEnter Subject...
When i enter the Total No of Student: 2
It will appear as 3 students on the for loop.
How to fix this?
thank you.
void main()
{
I’ve been working on this program and can’t solve the errors.
The correct output should be –
Enter Subject Code : BKG 121313
Enter Subject Name : C Programming Class
Enter Total No of Student :...
How can I declare ’M’?
There will be 2 errors if I write int M
syntax error before int
‘m’ undeclared (first use in this fuction)
Here’s the code-
thanx Adak.
I managed to fix it.
#include<stdio.h>
#include<string.h>
void main()
it says - syntax error before '}' token . its at the end of the code.
and im not sure about the while (choice=='p').
any ideas? thx!
The question -
Write a program that gets user selection on which item to purchase. Display the proper menu for this. User will enter ‘P’ to select Pie and ‘C’ to select Cake.
If user selects...
thank you everyone and adak. r
this is the final answer.
#include<stdio.h>
#define tax 1.0825
#define TV_price 400.00
#define VCR_price 220.00
#define Remote_Controller_price 35.20
I have to do like this total_price=TV_price*quantity ?
what if the stuff is VCR, Remote Controller, CD Player and Tape Recorder? do i have to repeat the same calculation all over again?
the question -
Write a C program to create a customer’s bill for a company. The company ARAFAT sells only five different products. They are TV, VCR, Remote Controller, CD Player and Tape...
Thanks Vart!
now its all ok!
Do u mean like this?
It skips the name ?
printf("\nEnter customer name : ");
scanf("%29[^\n]",customer_name);
printf("\nEnter weight [KG] : ");...
Adak - The Yes No at the start is to ask and check whether there is any customer at that time. Thank you Adak for helping me out!
This is the latest code i've been working on. Everything looks ok,...
You are right Adak. I think the variable x should be out. I did it base on the output example that shown only 3 customers.
I noticed there's something wrong -
The 'Thank You' will appear 2 times....
Thank you for your help people. I think i manage to do the YES and NO.
but there is some questions -
1- how can i display total customer?
2- where should i put the fflush?
thank you again
Hello. I’m new to C-programming. Can anyone help me out? I can’t find the code to solve this-
• Display a WELCOME MENU.
• Ask the user if they would like to continue. ‘Y’ to continue and ‘N’ to...