problem with c

This is a discussion on problem with c within the Tech Board forums, part of the Community Boards category; till now i have been studying c language for nearly two months. most of the c function i can understand ...

  1. #1
    Registered User
    Join Date
    Nov 2010
    Posts
    42

    problem with c

    till now i have been studying c language for nearly two months. most of the c function i can understand now. but i still find no improvement in myself. i try to read a lot of book. and searching Internet. but my ability still poor. could anyone help me. how to be strong in c language? step by step. thanks in advanced.

  2. #2
    Registered User ssharish2005's Avatar
    Join Date
    Sep 2005
    Location
    Cambridge, UK
    Posts
    1,682
    Reading books wouldn't help that much will have to practice these things. If you see a program on a book or any tutorial, try implementing it yourself, rather than just copying and pasting it. It is very important you have hands on experience to learn. When you try implementing yourself you're bound to have error and try resolve and you so and you start accumulating experience and learn more!

    ssharish
    Life is like riding a bicycle. To keep your balance you must keep moving - Einstein

  3. #3
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by hugoguan View Post
    till now i have been studying c language for nearly two months. most of the c function i can understand now. but i still find no improvement in myself. i try to read a lot of book. and searching Internet. but my ability still poor. could anyone help me. how to be strong in c language? step by step. thanks in advanced.
    Two simple words of advice: Write Code.

    We don't learn by reading, we learn by doing.

  4. #4
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Quote Originally Posted by hugoguan View Post
    till now i have been studying c language for nearly two months. most of the c function i can understand now. but i still find no improvement in myself. i try to read a lot of book. and searching Internet. but my ability still poor. could anyone help me. how to be strong in c language? step by step. thanks in advanced.
    Also, stick around to this forum and attempt to solve or identify problems that people are having trouble with. Copy and paste the code in your own IDE and try to debug the program.

    You learn a lot by reading and writing code.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  5. #5
    Registered User ssharish2005's Avatar
    Join Date
    Sep 2005
    Location
    Cambridge, UK
    Posts
    1,682
    I guess we should move this thread to general discussion forum perhaps?

    ssharish
    Life is like riding a bicycle. To keep your balance you must keep moving - Einstein

  6. #6
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,558
    As others have said - practice practice practice!

    10000 hour rule - Google Search

    If you've written tic-tac-toe, then
    - make is 2 player
    - add better graphics
    - add sound
    - make it playable over the network.

    If you used an array in a simple project, re-write it using a linked list instead.
    Study why one was better than the other.

    Read everyone else's homework answers on this (and other forums). See if you can spot the bugs.
    See if your answers stand up to review by other people. Good or bad, you'll learn a lot either way.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  7. #7
    Registered User
    Join Date
    Nov 2010
    Posts
    42
    thanks very much for the advice. but i myself seem don know how to start to practice since i don know what program should i write. i have no idea.

  8. #8
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,558
    > but i myself seem don know how to start to practice since i don know what program should i write
    How about the next homework assignment posted on the board, which you haven't done yourself?

    Not to spoon-feed the poster you understand, just for your own purpose to see if you can do it.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need help understanding a problem
    By dnguyen1022 in forum C++ Programming
    Replies: 2
    Last Post: 04-29-2009, 04:21 PM
  2. Memory problem with Borland C 3.1
    By AZ1699 in forum C Programming
    Replies: 16
    Last Post: 11-16-2007, 10:22 AM
  3. Someone having same problem with Code Block?
    By ofayto in forum C++ Programming
    Replies: 1
    Last Post: 07-12-2007, 08:38 AM
  4. A question related to strcmp
    By meili100 in forum C++ Programming
    Replies: 6
    Last Post: 07-07-2007, 02:51 PM
  5. WS_POPUP, continuation of old problem
    By blurrymadness in forum Windows Programming
    Replies: 1
    Last Post: 04-20-2007, 06:54 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21