Search:

Type: Posts; User: ljgerr93

Search: Search took 0.00 seconds.

  1. Welp, I've confirmed what I said above. I'm back...

    Welp, I've confirmed what I said above. I'm back in business until further notice!
  2. Oh, and here's what the input file looks like: ...

    Oh, and here's what the input file looks like:

    5
    Llewellyn Mark
    1 15 19 26 33 46
    Young Brian
    17 19 33 34 46 47
    Cazalas Jonathan
    1 4 9 16 25 36
    Siu Max
  3. Even after fixing it or removing the code, the...

    Even after fixing it or removing the code, the program STILL crashes. The only thing I didn't try doing is freeing up memory for the array of structs, but A. that will be done in another test file I...
  4. typedef struct { char firstname[20]; ...

    typedef struct
    {
    char firstname[20];
    char lastname[20];
    int numbers[6];
    } KBLottoPlayer;


    I also tried to declare without typedef (struct KBLottoPlayer), and it still crashes.
  5. Trouble with reading in data to an array of structs

    I've broken down the huge program I was recently assigned into several parts, and this is the first. I'm trying to read in data from an input file and store each piece into structs in an array. Here...
  6. Replies
    23
    Views
    2,014

    Yeah, I hear you. Well, FILE *ofp is definitely...

    Yeah, I hear you. Well, FILE *ofp is definitely declared to write a file, and I don't have anything that would tell it to close the file until the very end of the program in main(). The .txt file is...
  7. Replies
    23
    Views
    2,014

    I can't use anything not mentioned in class, as...

    I can't use anything not mentioned in class, as convenient as it would be. And there's nothing wrong with the data (I used printfs to test, and it works perfectly); it's how I'm telling the program...
  8. Replies
    23
    Views
    2,014

    Even if I declare FILE *ofp in printGuestList, it...

    Even if I declare FILE *ofp in printGuestList, it still doesn't work. Besides, I had that format for the FILE *ifp that scanned in the values from the sample input file (in other words, FILE *ifp was...
  9. Replies
    23
    Views
    2,014

    I do that in the main function, before...

    I do that in the main function, before printGuestList is called.
  10. Replies
    23
    Views
    2,014

    Okay, sorry to bump this back to life, but...

    Okay, sorry to bump this back to life, but there's one more issue. (This should be very easy to fix for those that have used it before.) So the final function is supposed to write a file with the...
  11. Replies
    23
    Views
    2,014

    Never mind! I found it, and the program works...

    Never mind! I found it, and the program works perfectly.
  12. Replies
    23
    Views
    2,014

    Here is what I want to do all together: 1....

    Here is what I want to do all together:

    1. From the list of everything I read in from the input file, I want to first sort the list by priority from least to greatest (in this case, 1 is more...
  13. Replies
    23
    Views
    2,014

    Oh, and by the way, it's not really bubble...

    Oh, and by the way, it's not really bubble sorting. It's an attempt at insertion sorting.
  14. Replies
    23
    Views
    2,014

    Actually, I did some experimentation with my list...

    Actually, I did some experimentation with my list and got it to print all the names alphabetically. However, now comes the challenge of implementing the priorities and printing out a target output....
  15. Replies
    23
    Views
    2,014

    Just for reference, here's the output file I get:...

    Just for reference, here's the output file I get:

    ESPINOSA, DOUG 3
    JAMES, ELIZABETH 2
    JOHNSON, BEN 4
    JOHNSON, JACKSON 1
    MCFLY, MARTY 4
    MOUSE, MICKEY 2
    TELLINGER, SARAH 5
    THOMPSON, GRANT 5
  16. Replies
    23
    Views
    2,014

    Oh, and I might ask for help with writing a file...

    Oh, and I might ask for help with writing a file later, but this comes first.
  17. Replies
    23
    Views
    2,014

    List Sorting Issues

    So my newest program involves making a guest list of people in alphabetical order based on a certain priority. (The priority part I can figure out later; for now, I just need the program to print the...
  18. How do I store a new value into an array in a completely different function?

    Never mind; I fixed it on my own!
  19. Replies
    4
    Views
    1,483

    That too.

    That too.
  20. Replies
    5
    Views
    2,565

    All right, it works now! Thanks for the tip, MK27!

    All right, it works now! Thanks for the tip, MK27!
  21. Replies
    5
    Views
    2,565

    Hmm...you know, that's a good point. A loop that...

    Hmm...you know, that's a good point. A loop that checks to see if an event is filled or not. If the spot in the array is still 0, which means free, then the spots for the times will be set to 1. If...
  22. Replies
    5
    Views
    2,565

    Thing is, I use a for loop like that to fill in...

    Thing is, I use a for loop like that to fill in the spots. I kind of see how I might use another loop with if statements to see if there are conflicts or not, but the picture doesn't come to mind.
    ...
  23. Replies
    5
    Views
    2,565

    Checking to see if an array is filled

    I'm working on two programs that both involve scheduling. The program reads in a data file, calculates some times (all in military), and fills in the appropriate spots with a 1. It then checks to see...
  24. Replies
    4
    Views
    1,483

    ...I could've sworn I put those in there. Well,...

    ...I could've sworn I put those in there. Well, it works now. Thanks for the good eyes!
  25. Replies
    4
    Views
    1,483

    Correction needed to make the program work?

    So at the moment, I am working with file I/O and data files. I'm working on a program that can select different days, months, and temperatures ranging from the years 1995 to 2011. My first step in...
Results 1 to 25 of 25