4

I'm a beginner cs student I'm learning c language now
Should i make note of all content ?
And plz suggest me good technique to learn that language ...plz !!

Comments
  • 0
    If notes help you, go ahead. But don't go too detailed unless you want to publish a book

    The technique is same old one. Read, practice, learn from mistakes, annd repeat
  • 1
    C is a simple language - but its simplicity is treacherous like thin ice in early winter.

    Compiler warnings are your friends, like local guides, because they tell you where the ice is thin.

    Always use them. For GCC, use "-Wall -Weverything -Wpedantic" as the most important ones. Your code should not show any warnings.

    If you have a warning that you don't understand, google it. Research what it means, what the danger is, why your code triggers it, and how to fix your code.
  • 0
    Learn TDD (Test Driven Development). It will better enforce concepts and it would impress employers if you upload you tests and classes to GitHub.

    Start writing a simple unit test to check to see if a "hello world" string is returned from a method. Then write the class to pass the unit test.
  • 1
    @Fast-Nop the language is simple, but the libraries are many.
  • 0
    @Voxera That comes on top, but even the language isn't quite easy. Quick check, can you answer what "ptr=malloc(0)" will do - without googling?
  • 1
    @Fast-Nop no, its been 20 years since I did any serious c programming ;)

    But my guess is that its not very useful but does not throw any error.

    And no I did not google it ;)
  • 0
    The school I go to teaches polymorphism, concurrency, and malloc in C. After the final, I throw everything out of the window and swear I am never touching C again.
  • 2
    @Fast-Nop The one time I wondered this is finally useful now ;)
    Either a null pointer or some garbage pointer is returned, it's implementation dependent.
  • 0
    @PrivateGER Correct, it's implementation defined, the worst compromise out of the two options. It also means that a bug in calculating memory needs may manifest in a subtly different way across platforms.
  • 1
    @Fast-Nop Ah, the joys of C...
  • 2
    @h3rp1d3v There's even exception handling in C. I have ever only seen one application where that did add more clarity, and never used it personally in decades, but it does exist.

    But, once you get C, it even helps you to write faster JavaScript. No shit, I don't often write it, but if I do, you can bet that it's dang fast.
  • 1
    @PrivateGER Yeah, and yet, and while I can do and have done stuff with quite some languages, C is the one I love - and luckily, C doesn't count inline assembly as adultery against me. ;-)
  • 0
    Instead of noting down I'd advice you to practice and practice until you remember the syntax, but if if something is not being easy don't worry there is always documentation to help you
  • 0
    Dear beginner, the only skill you need is acceptance of failure. You will face the failure 1000000000x more than any pleasure. Btw C is the father of everything we use today, I respect it, it is a garbage language.
  • 1
    @Fast-Nop C is faster than JS? I hope you mean in runtime...
  • 0
    Suggestion: don't
  • 0
    @Fast-Nop sorry but I'm learning functions right now i don't know anything about it
  • 0
    @h3rp1d3v 😂😂
  • 0
    @molaram sorry but what are u trying to tell me ?
Add Comment