Search:

Type: Posts; User: CyC|OpS

Page 1 of 2 1 2

Search: Search took 0.00 seconds.

  1. Replies
    1
    Views
    14,570

    anyone?

    anyone?
  2. Replies
    1
    Views
    14,570

    half ADT (nested struct) problem...

    Hi,

    I ve got problem in implementing ADT in my program,
    below I posted my PQ.c, PQ.h -> which is the ADT (not full ADT) you'll see why in my code...and office.c+ office. which is the program...
  3. Replies
    9
    Views
    1,618

    Got it now, thanks so much for your help :) ...

    Got it now,

    thanks so much for your help :)

    Ferdinand
  4. Replies
    9
    Views
    1,618

    thanks Hammer, but that doesnt anwser my...

    thanks Hammer,

    but that doesnt anwser my question,



    I am confuse coz free( Array ) doesnt free the memory ( I still can access them...
    and free( &Array[1] ) OR free( &Array[number between...
  5. Replies
    9
    Views
    1,618

    thanks Prelude + Moi, I ve got the idea...

    thanks Prelude + Moi,

    I ve got the idea now....
    but got another problem...

    if I got this structure...



    struct arr
  6. Replies
    9
    Views
    1,618

    memory allocations probs (continue)

    Hi,

    just wondering if I am allocation (totalsize) * (sizeof mystructarray), is it normal if it gives me segmentation fault when I am trying to access mystructarray[totalsize+1]?

    just wondering...
  7. Replies
    8
    Views
    2,280

    hei thanks to both of you, Hammer : yeah,...

    hei thanks to both of you,

    Hammer : yeah, maybe I just give up the description dynamic memory allocation...should be alot easier...

    Salem : I'll try to read the file first and allocating...
  8. Replies
    8
    Views
    2,280

    Thanks Hammer & Salem for your help, for...

    Thanks Hammer & Salem for your help,

    for Hammer : I must use dynamic memory unfortunatly.

    for Salem : ypu're right....I dont know the size of the file.. =( , is there any other way to...
  9. Replies
    8
    Views
    2,280

    is this mean I can't use &string[i]?

    is this mean I can't use &string[i]?
  10. Replies
    8
    Views
    2,280

    umm..I "know" that was the problem, and I tried...

    umm..I "know" that was the problem, and I tried to allocated memory for TRec, but honestly I dont know where should I do it, and I dont know the size of TRec (how many tasks are in the array)...and...
  11. Replies
    8
    Views
    2,280

    memory allocation problem....help..

    Hi, I got a problem with memory allocation (that's my assumption) in my prog...
    My program purpose is to read from file and put it inside the struct array TRecord.

    this is the file format:

    ...
  12. Replies
    16
    Views
    2,296

    yeahhh, I ve just figured that out and want to...

    yeahhh, I ve just figured that out and want to post it...
    thanks anyway Hammer :)
    I ve got alot of very helpful response from this board

    btw, i ve just voted for u ^_^

    CyC|OpS
  13. Replies
    16
    Views
    2,296

    exactly!!! I ve one variable which i declared...

    exactly!!!

    I ve one variable which i declared as global variable inside header file..and i didnt declared it in other source file...

    int var = 2;

    how can i overcome this prob??

    CyC|OpS
  14. Replies
    16
    Views
    2,296

    there's no error when i compile the object files...

    there's no error when i compile the object files
    > gcc -c maindriver.c
    > gcc -c functions.c

    however it gives errors when
    > gcc -g -Wall -o progname maindriver.o functions.o

    the prog working...
  15. Replies
    16
    Views
    2,296

    anyone can help? I ve worked on it for the whole...

    anyone can help? I ve worked on it for the whole night and still can't figure it out...

    *_*
  16. Replies
    16
    Views
    2,296

    thanks Shiro :) thats explain alot... I...

    thanks Shiro :)

    thats explain alot...

    I just finished separating my program...
    the skeleton is exactly the same as Strider post above..

    however, when i compile it

    > gcc maindriver.c...
  17. Replies
    16
    Views
    2,296

    #ifndef FUNCTIONS_H #define FUNCTIONS_H /*...

    #ifndef FUNCTIONS_H
    #define FUNCTIONS_H

    /* function here...*/

    #endif



    how is this #ifndef & #endif work??
  18. Replies
    16
    Views
    2,296

    hi David, thanks for your explanation...very...

    hi David,

    thanks for your explanation...very clear :)

    now how to compile it?
    issit only calling the main.c

    eg: gcc main.c

    or i need to call the dependecies too? .h and functions.c?
  19. Replies
    16
    Views
    2,296

    C header files?

    hi,

    I ve questions bout header files...
    for example if I have main function like below, how can i separate it into .c and .h files, to make it neat and more efficient..




    #include <stdio.h>
  20. Replies
    5
    Views
    11,787

    um...nobody can help issit? :( or u guys dont...

    um...nobody can help issit? :(
    or u guys dont understand what is my question?
  21. Replies
    5
    Views
    11,787

    reading/scanning array of structure ??

    Hi,

    I ve array of structure..



    struct record
    {
    int key;
    char *word;
  22. oh okie... i dont know about that =) I think...

    oh okie...
    i dont know about that =)

    I think thread closed now.
  23. Thanks Salem!!! It did workingggg, omg i dont...

    Thanks Salem!!!

    It did workingggg, omg i dont believe it...

    thank you very much :)

    o yeah about the malloc... do u mean that I dont need to allocated the memory?


    sincerely,
  24. cygwin -> unix , my code not working properly ;(

    Hi,

    I recently make this code to concate 2 string...i am using cygwin at home...and this code working as i expected :


    char *str_concat( char *string1, char *string2 )
    {

    char *string3;...
  25. Replies
    1
    Views
    859

    C tutorial E-Book...

    Hi,

    anybody know where I can find a good E-book for C, dont have enough money to buy a real book....

    thx

    Ferdinand
Results 1 to 25 of 27
Page 1 of 2 1 2