Thanks. Didn't know about this site..
Type: Posts; User: The Monkey King
Thanks. Didn't know about this site..
For example: is a linked list a data structure? That's what I mean when I say I don't understand what the topic is asking. I've been looking it up in my book, I looked through the faq, but I came up...
Yeah, I just made that up because I don't understand what that crappy explanation of what I need to know is asking.
Example:
Is this right?
Data for a structure is accessed with a pointer (->). Data is stored as a _____? The type of memory is ____.
That's all I need to know for the structures and and...
thanks, but we didn't get into the coding part of it. I still read through it, but didn't find any answers to my question (maybe because I don't know a thing about the actual coding part). Can...
Okay, so I have a test tomorrow and there is a topic that I need to know that's not in my notes and apparently is not in my book either.
Here's what I was told to know about Linked Lists:
(my...
Yes! It works! Thanks for the help everyone!
So do I need a separate if-else statement or a loop (for loop)? Maybe a while loop?
I got it to work.
lol, I wish I could do the second part of what you said, but unfortunately my instructor's inbox is full and she's never at school, plus it's due at 8 AM tomorrow so not much I can do in that...
Oh, crap. It looks like the instructions demand binary search.
So if SSNs are last in priority in sorting, is searching for it using a binary recursive search function even possible?
Okay.
You mean sequential search (We never went over linear searching if that's what it's called)?
Oh, hang on a second. The instructions say that it should be sorted by last name, then first name, then (if both of those are the same) SSN. So basically, it's sorted the same way as my professor's...
Oh, I see. Okay, I remember having this problem earlier today about sorting the names. So for now I just have to switch the first name with the ssn, right?
So could this be the problem?
void sortArr(STUDENT student[], int last)
{
int i;
for (i = 0; i < last - 1; i++)
exchangeSmallest (student, i, last);
Okay, so it's B, sorry I must've posted at the same time as you.
Would this rule out the first possibility?
typedef struct
{
int month;
int date;
int year;
} DATE;
Yeah, it's weird. It's only printing the last index in the sorted list.
Here is the list:
Jane Doe 5 444-44-4444 09/27/2000
John...
I'm wondering if this has anything to do with it:
if (lb > ub)
{
result = -1;
Yes, all of them are in the file.
Here's the output:
Please enter social security number (press q to quit): 444-44-4444
Record found at index -1:
0ùÿ¿ 42 P 00/-1073742860/ 127...
Okay, part of it works...one part to be exact.
Here's the output for all the SSNs that I searched. Only the last one worked:
q did make the program exit, but it still output a bunch of random...
Well it's supposed to be reading the arrays from a file, I believe, so whatever is in the file is what the SSNs are.
Same here. I thought our function already searched both ways like you said. I had no idea it was only searching one way. Wouldn't that just be sequential search? I thought ours was in binary.