Search:

Type: Posts; User: Mahdi123

Search: Search took 0.00 seconds.

  1. Replies
    2
    Views
    1,890

    confused with pointers

    ok so I'm writing a program that will read a data file with 30 integers in it into an array, then pass the array to a function that counts the number of positive numbers, zero's, and negative...
  2. Replies
    2
    Views
    1,006

    How would I do this?

    I have a data file filled with random numbers, I need to read the numbers into an array and count the numbers read. Maybe Im just being an idiot right now, but for some reason I can't think of how...
  3. Replies
    5
    Views
    1,730

    ahhh ok thanks, I knew it would be something...

    ahhh ok thanks, I knew it would be something stupid like that I would forget.

    Also, gets() is just what they told me to use in class, but I shall promptly inform myself otherwise.
  4. Replies
    5
    Views
    1,730

    Program crashes, why?

    I'm writing a program to read in user intered values for a country (read into a 2D character array) and 2 different types of values (into a 2D float array) and calculate a third value. I wrote out...
  5. Replies
    7
    Views
    4,173

    haha, looks like that was the problem - I...

    haha, looks like that was the problem - I could've sworn I already had that ampersand there, if I had noticed it I would've fixed that myself. Anyways its working for what I have now, thanks for the...
  6. Replies
    7
    Views
    4,173

    Alright, I did what Salem suggested and also...

    Alright, I did what Salem suggested and also tried changing the function read2D() to a void function; however, both ways still give me the "process died on signal 11" error.
  7. Replies
    7
    Views
    4,173

    Ok so I rewrote everything thusly: ...

    Ok so I rewrote everything thusly:



    #include <stdio.h>
    #define nRows 8
    #define nCols 7
    #define FILENAME "assign8in.txt"

    int read2D(int array[][nCols], int numRows, int numCols);
  8. Replies
    7
    Views
    4,173

    Compiles fine, freezes when Run?

    I'm working on an assignment and ran into some problems about halfway through my code, so I decided to start over going a little slower now. However now I've written the first two functions and they...
  9. Replies
    8
    Views
    1,496

    alright gotcha, its working now, thanks for the...

    alright gotcha, its working now, thanks for the help
  10. Replies
    8
    Views
    1,496

    I changed this void belowaverage(int...

    I changed this



    void belowaverage(int array[nRows][nCols], int numRows, int numCols)
    {
    float average=0;
    int i, j, sum=0;

    mean(array, numRows, numCols);
  11. Replies
    8
    Views
    1,496

    Anything obviously wrong here?

    I'm writing the code for my newest class assignment and I've been writing it in pieces to try and work out bugs along the way, so far the only problem I have is that the file I am reading from is...
Results 1 to 11 of 11