Search:

Type: Posts; User: jimtuv

Page 1 of 4 1 2 3 4

Search: Search took 0.01 seconds.

  1. It might be easier for you if you add a function...

    It might be easier for you if you add a function to print n characters

    void print_char( int n, char ch);

    now in this function do a loop to print ch n times; then all you will have to do is call...
  2. Replies
    10
    Views
    13,254

    This may explain why you should be using ...

    This may explain why you should be using




    int main (void){

    //your program goes here

    return 0;
  3. That explains alot. I kinda figured it might be...

    That explains alot. I kinda figured it might be VS. Your right that scanf can be dangerous, its because the input can exceed the size of the array it is being put into. MS added scanf_s so not all...
  4. beyond the very dangerous gets(); or the use of...

    beyond the very dangerous gets();
    or the use of fflush(stdin);
    both really bad ideas

    you should get errors on compiling this. scanf_s is an undefined reference. I think you ment to say...
  5. Replies
    18
    Views
    3,482

    Since Blender so heavily relies on Python I will...

    Since Blender so heavily relies on Python I will definitely learn that for sure. Here is a hand study I drew a few weeks ago.

    http://i40.photobucket.com/albums/e210/jimtuv/Handstudy.jpg

    I...
  6. Replies
    18
    Views
    3,482

    I forgot to say thank you for the links. I had...

    I forgot to say thank you for the links. I had already found the first GTK+2.0 Tutorial. That is where I got the info to build the above code. The other two I haven't seen yet but will dig through...
  7. Replies
    10
    Views
    13,254

    you should use int main (void) and at...

    you should use


    int main (void)


    and at the bottom
  8. Replies
    8
    Views
    1,193

    I think you are thinking of (*foo).x=12 ...

    I think you are thinking of


    (*foo).x=12


    see the dot . is evaluated first before *. So to force the dereference to occur first you add the parenthesis. This is exactly the same as saying
  9. Replies
    18
    Views
    3,482

    I do definitely understand that Linux has many...

    I do definitely understand that Linux has many desktop environments. Gnome, KDE, Xterm and many more even one for kids Sugar. I think If I were to develop apps for KDE I would most likely go either...
  10. Replies
    18
    Views
    3,482

    I will definitely research "model view...

    I will definitely research "model view controller". From the quick scan I did at Wikipedia it sounds like a very good idea indeed.

    I made my first pop up window. What I learned from it is; always...
  11. You should get an error here get_name...

    You should get an error here


    get_name (person , 5);

    get_name doesn't have that many parameters.


    void get_name (struct EMPLOYEE person []);
  12. Replies
    21
    Views
    3,653

    The problem in all of this is that if your...

    The problem in all of this is that if your premise is not true then all the conclusions based upon that premise are also invalid. One sign of a bad premise is a constantly changing conclusion. Maybe...
  13. Replies
    20
    Views
    7,528

    This is legal int x; x = 'c'; ...

    This is legal


    int x;

    x = 'c';

    printf("%d = x\n",x);
  14. Replies
    18
    Views
    3,482

    I kinda figured C++ may come in here soon so I...

    I kinda figured C++ may come in here soon so I already picked up a book from the library. I also am exploring Ruby and Python as well. It's funny a few weeks ago I didn't have a clue about any...
  15. Replies
    18
    Views
    3,482

    When to switch from console apps??

    I have written quite a number of console programs now and wondered at what point in learning C is it beneficial to begin to learn to make a GUI.

    So far I have studied
    Algorithms
    Variables...
  16. Replies
    13
    Views
    13,911

    Didn't know if this will help but I made a couple...

    Didn't know if this will help but I made a couple changes to MK27's example to show exactly what the memory addresses look like and how subtracting response from p gets the index number.

    ...
  17. Don't feel bad passing function parameters can be...

    Don't feel bad passing function parameters can be a bit tricky. I am new as well and have to really think carefully what is being passed and how. I found this link to be helpful

    Passing Arguments...
  18. Replies
    52
    Views
    4,874

    That was a silly mistake. I don't need an array...

    That was a silly mistake. I don't need an array of char pointers there it was a typo didn't even realize I did it. Must have done that a when I changed it to an array a couple days ago. I was...
  19. Replies
    52
    Views
    4,874

    Spent some time tonight playing with the code. I...

    Spent some time tonight playing with the code. I added a index array of pointers then pointed them to the struct and did a swap on just the pointers in the array leaving the struct unaffected yet...
  20. Replies
    52
    Views
    4,874

    Wouldn't this be true of most any function I were...

    Wouldn't this be true of most any function I were to use?? I mean when I was studying user input and learning to use fgets I needed to be sure to send the correct size to it. scanf can be a disaster...
  21. Replies
    52
    Views
    4,874

    This is another area I have rethought. It would...

    This is another area I have rethought. It would be better to shift the data down over the "deleted" element rather then just putting in values out of range. So you would copy the next element on to...
  22. Replies
    52
    Views
    4,874

    Wow you were fast. I was just about to edit this...

    Wow you were fast. I was just about to edit this out. LOL



    Just thinking how someone would set up the function for deleting a node. If it should be done recursively or iteratively.
  23. Replies
    52
    Views
    4,874

    yep no difference there but that's not what you...

    yep no difference there but that's not what you had before. This is the way you put it first.



    So I was speaking of breaking the height into feet and inches.



    You can't delete an element...
  24. Replies
    52
    Views
    4,874

    Ok only had a little time to code today so I...

    Ok only had a little time to code today so I fixed the lack of an initializing function I set up


    void Init_person(personal_info *client, char name[NAME_SIZE],
    int feet, double...
  25. Replies
    3
    Views
    16,885

    Glad you found that. In the future a look a the...

    Glad you found that. In the future a look a the faq or google search may get you the answer without starting three threads with the same question

    Cprogramming.com FAQ
Results 1 to 25 of 94
Page 1 of 4 1 2 3 4