s2xcracker's Profile User Rating: -----

Reputation: -7 Shunned
Group:
Active Members
Active Posts:
51 (0.03 per day)
Joined:
30-January 10
Profile Views:
4,737
Last Active:
User is offline Dec 18 2012 05:07 AM
Currently:
Offline

Previous Fields

Dream Kudos:
0

Latest Visitors

Icon   s2xcracker has not set their status

Posts I've Made

  1. In Topic: Trying to find the error..

    Posted 18 Dec 2012

    View Postgirasquid, on 15 May 2007 - 02:30 PM, said:

    What exactly is going wrong? We can't help you without knowing what problem you're having exactly.

    I had assigned the same problem at my uni and here's the error
    [Linker error] C:\Users\S2xC\AppData\Local\Temp\ccRHZNiO.o:main.cpp:(.text+0x1d): undefined reference to `Universe::Universe()'

    Could you please help me ? =/
  2. In Topic: Creating a simulation

    Posted 18 Dec 2012

    View Postsidharth, on 29 November 2006 - 04:32 AM, said:

    wait for 2 days
    ishall post the code here
    it seems interesting
    ;)/>


    I don't really want to be annoying, but could you please write the code if it is not difficult for you because I have assigned the same project at my uni and I can't get it right =/ and the deadline is on Thursday.I will really appreciate if you can do it please.
  3. In Topic: Read from file into an array pointer

    Posted 9 Sep 2012

    View Postjimblumberg, on 06 September 2012 - 10:28 AM, said:

    Quote

    Thank you but still could you please help me with that peace of code ?

    I did, read the links I provided.

    Quote

    Oh...and how to make my function return pointer to an array ?

    I did, study the function tutorials I provided in my signature.

    After you study the links provided, give it a try. If after giving it a try you still need help, post your new code, the complete error messages exactly as they appear in your development environment, and ask specific questions based on your new code.

    Jim

    Here's what I've written so far but for some reason my program crushes whenever I use pointers(it works with 2d array):
    FILE *file;
        int c;
        char **file_buffer;; //[10][17]
        file_buffer = (char**)malloc(sizeof(char)*10);
        for(int x=0;x<17;x++){
                file_buffer[x] = (char*)malloc(sizeof(char)*17);
                }
        file = fopen("C:\\Users\\S2xC\\Documents\\sudoku.txt","r");
        for(int x=0;x<10;x++){
        for(int y =0;y<17;y++){
                fscanf(file,"%c",&file_buffer[x][y]);
                }
                            }    
    
    


    View Posts2xcracker, on 09 September 2012 - 08:54 AM, said:

    View Postjimblumberg, on 06 September 2012 - 10:28 AM, said:

    Quote

    Thank you but still could you please help me with that peace of code ?

    I did, read the links I provided.

    Quote

    Oh...and how to make my function return pointer to an array ?

    I did, study the function tutorials I provided in my signature.

    After you study the links provided, give it a try. If after giving it a try you still need help, post your new code, the complete error messages exactly as they appear in your development environment, and ask specific questions based on your new code.

    Jim

    Here's what I've written so far but for some reason my program crushes whenever I use pointers(it works with 2d array):
    FILE *file;
        int c;
        char **file_buffer;; //[10][17]
        file_buffer = (char**)malloc(sizeof(char)*10);
        for(int x=0;x<17;x++){
                file_buffer[x] = (char*)malloc(sizeof(char)*17);
                }
        file = fopen("C:\\Users\\S2xC\\Documents\\sudoku.txt","r");
        for(int x=0;x<10;x++){
        for(int y =0;y<17;y++){
                fscanf(file,"%c",&file_buffer[x][y]);
                }
                            }    
    
    
  4. In Topic: Read file into 2d array pointer

    Posted 8 Sep 2012

    View PostSalem_c, on 08 September 2012 - 05:03 AM, said:


    I am just trying to find an answer as soon as possible guys.... =/
  5. In Topic: Read from file into an array pointer

    Posted 6 Sep 2012

    View Postjimblumberg, on 06 September 2012 - 09:37 AM, said:

    Why are you trying to use C file methods instead of using C++ streams? Second your ReadFromFile() function was defined to return a single char, not a pointer to an array. I really think you should study the following links: Arrays, File I/O as well as the function tutorials contained in my signature.

    Jim


    Thank you but still could you please help me with that peace of code ? Oh...and how to make my function return pointer to an array ? Please help me you if can.

My Information

Member Title:
D.I.C Head
Age:
Age Unknown
Birthday:
Birthday Unknown
Gender:

Contact Information

E-mail:
Click here to e-mail me

Friends

Comments

s2xcracker has no profile comments yet. Why not say hello?