thanks, it worked. now i have to edit so it can count for occurances. YAH!
Type: Posts; User: killerasp
thanks, it worked. now i have to edit so it can count for occurances. YAH!
here is the code that is causing the error
list_of_strings *add_to_list(list_of_strings * start, char dumb[])
{
list_of_strings *tmpptr = start; // (1)
start = new(list_of_strings); //...
ive tried re-working the code, but i keep coming with idea. it it randomizes but it still will intsert the value in the array even thoughh counter>4. when i try to output the array of values, it...
good point with the counter. let me try that
im still having much trouble. I want the rand to generate a number btw 0-52. and check its value with previously generated values that are stored in array. if a match occurs more than 4 times ,...
and i what i got was an endless loop. gotta work that out!
im working a card program that will shuffel and display the cards. im trying to randomize numbers but this code will not print anything. it seems like it goes into an endless loop.
for(int...
but if its a class function, isnt it already global?
is their a way to call a class function within another class function?
Im supposed to make a program that reads an input file and outputs the number of times a certain work appears. i did it using strcmp but he wants it using linked lists. i dont see how this is...
but what is
struct list_of_strings * next;
for?
struct list_of_strings
{
char data[80];
list_of_strings * next;
};
arent you supposed to put something infrom of list_of_strings?
if(strcmp(dumn, temp.) data) == 0)
count++;
temp = temp->next;
what is the "->" used for?
* list_of_strings add_to_list(list_of_strings *, char []);
thats the line in the C++ code i got. i dont know what it is.
ive been up for 2 days now. yes thats 48 hrs. my teach wants us to create a calculator that can do complex number. he wants use to have functions take in values, functions that take those values and...
will i be able to use a pointer in a function with out passing it in func (variable)?
Im supposed to work on a program that invloves the use of pointers. Im not even going to ask about structs because its way beyond my understanding. But what is the point of using pointers if it just...