I really need urgent help on this: i need this 2D array program [C/C++] please help
+ Reply to Thread
Results 1 to 4 of 4

Thread: I really need urgent help on this: i need this 2D array program [C/C++] please help

  1. #1

    Lightbulb I really need urgent help on this: i need this 2D array program [C/C++] please help

    Write the pseudocode (algorithm) for the following program definition: A text file contains 100 characters that you will read into a square array of characters size 10x10 (this will be a 2D array of characters, not strings - you will need to read character by character). The program will call one user-defined function to determine if all the characters on the main diagonal (top-left to bottom-right) are the same.

    The function is called checkdiag (header/prototype: int checkdiag (char matrix[][10])) and will return 1 if all the characters on the main diagonal are the same and 0 otherwise.

    Your program will read the array from the file, check the diagonal and print a report printing the array and the status of the diagonal. A typical report would look like

    a b c d e f g h i j
    b a c d e f g h i j
    b a a d e f g h i j
    b a c a e f g h i j
    b a c d a f g h i j
    b a c d e a g h i j
    b a c d e f a h i j
    b a c d e f g a i j
    b a c d e f g h a j
    b a c d e f g h i a
    All the characters on the main diagonal are the same.

  2. #2

    Default

    By Thursday night i need it.........i dont know how to do this..

  3. #3

    Default

    Is it Okey for you if it is done on UNIX platform ?
    If so it is a very small piece of program to achieve your requirement


    = sankarcs

  4. #4

    Default

    hi sankarcs

    it would be nice if it in windows based..

+ Reply to Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts