with reference to your point
how do i fix this problem? Brad
Type: Posts; User: brad123
with reference to your point
how do i fix this problem? Brad
Hi can anyone explain why my program isnt working properly. Wen u go to option 2, files, the file editing, it doesnt show the correct amount of entries.
Brad.
#include <stdio.h>...
Thanks prelude thats sorted it :)
Brad.
yes i think you are on track with wot i mean hammer, after i type in the variables into the maths program and i have a result how do i return to the previous menu? Thanks
Brad.
thanks prelude, ok, how can i return to the main function from functions above the main?
Brad.
i made it work by changing the choices on the maths list to A and not 1 (i dont know why this had an effect). Now the probelm seems to be that it is looping twice before i can type anything( it'd...
thanks hammer but that wasnt it, that was just me trying to change the declaration from int to char and left it like that accidently before i copied it to this thread, any other suggestions? :)
Hi im writing a program for a project and dont know why i cant refer to the math1 funtion from inside the void option1(void) function(see below) any insight into this would be appreciated.
...
sorry about not using tags, the program works if i hide the printf line, but obviously wont display the answer because that line is needed for that. im just wondering why it isnt working :)
Brad.
can anyone explain why this isnt working? The printf that ive hidden from the compiler seems to cock it up??
CODE:
#include <stdio.h>
#include <clib.h>
struct dat{
Is there a way to clear screen after a while loop has taken place, so it starts program again but not at the bottom of the last text?
Brad.
im having problems calculating the number of days until the 25/12/2002,
here is my program (attached) so far, i know its messy but have a look and see wot i can do, thanks,
Brad.
after putting this code into my programme:
printf("\n\nOk, please enter a word to look for in this sentence.\n");
scanf("%s", &word);
char *delims = { " .," };
...
cheers hammer, brad.
ok , ive put this piece of code in:
if (strcmp(ptr, "is") == 0)
from hammer, all i need to do now is make the search word not a constant ("is"),
if i use the line
scanf("%c", &word);
thanks again prelude, but ive never used this function strtok before and although uve shown me wot to do could i trouble you again to help me integrate it into my program? its the final piece in the...
baically, i need to know how to count how many times an inputed word appears in sentence 2. any ideas?
Brad.
can anyone tell me why this programme isnt working? its meant to count how many words that you enter appear in the second sentence. run it and see wot i mean. Thanks,
PROGRAMME:
#include...
thanks prelude, ive solved it now :), it was a mix up of terms...
code:
else if (t.month == 2 && t.day == 29&& leap != 0)
printf("ERROR, the year you entered isnt a leapyear.\n");
else if...
cheers, but it compiles and builds this program on my compiler, its just that it doesnt recognise the correct leap years, ie it thinks 2001 was one and 2000 wasnt.?
Brad.
can anyone see wot ive done wrong in this piece of code? it doesnt recognise leap years accurately.
code:
struct dat{
int day;
int month;
int year;
};
if the code is fine then maybe something else is wrong, it compiles the file with no problems but when trying to build it and run, it says the failure is a result of a failed compilation?? i dont...
can anyone tell me y this doesnt work please, and how to make it work?
/* ---------------------------------------------------------------------- */
/* Program to calculate # of days...
cheers.
Brad.
sorry guys for wastin your time, and i didnt mean to be rude, its just im no expert with c nor will i ever be, but for this particular module, it is very important. Brad.