I know something about computers and a very little about programming. I want to learn more.
Would it be wise to read The C Programming Language (2nd Edition) and get deep dive straight into the core or to learn some python or JS?
Ape Out Shirt $21.68 |
Ape Out Shirt $21.68 |
I'd prefer to get practical, hands-on first and then learn the theory once I'm hooked or stuck.Bbut I've never read any of these programming books so I can't comment on their usefulness.
Pick up the King’s modern C book if you want to learn C.
That book is outdated. I would suggest you watch some videos about computer science concepts first and then read this.
Hey bros. Where's the best place to get this book? I'd prefer not to spend $55 on eBay for a copy.
You have some good links in archived /chad/ generals. Pasting them here.
WIKI: https://wiki.installgentoo.com/wiki//chad/
K&R: https://files.catbox.moe/rfhegv.pdf
KING: https://files.catbox.moe/a875c2.pdf
Modern C: https://files.catbox.moe/xeb93p.pdf
Is it autistic to want a physical copy?
Thanks. This would save me a few dollars. Looks like it's hard to find a copy for much less than $50.
I bought a physical copy of K&R and I sort of regret it. It's nice to have, and I can work on the exercises with nothing but a pencil and paper and no electricity if I really want, but I can't figure out how to keep it open on my desk without fearing I'll damage the spine.
Thanks for the perspective. I'm autistic about damaging my books too but I don't want to fork out even more money for an eReader. I'll have to think on this.
Why not just use 2 or 3 monitors? It's the most convenient way when you're doing exercises from a programming book.
I'm a Thinkpad plebeian
Ah.
PDFs kinda suck on most e-readers anyway. You see a real advantage of e-readers when it's just reflowable text like in a novel. When it's something with larger pages, like a textbook, the you just get inconvenience and tiny letters.
I think I will probably just shell out the dough for a used copy. There's something metaphysically satisfying about physical copies of a book anyway. And since it's already used, I won't be as obsessive over maintaining the quality. Plus I will feel like smart hacker man when it's on my bookshelf.
https://www.bookfinder.com/
This is the way to do it, do the exercises and programs at the end of each chapter as well.
I fricking hated doing them, like evaluating clusterfricked code using pen and paper or writing clusterfricked code using only what the chapter and previous chapters taught when there is a one line option to do what you want but it's 10 chapters away.
That being said, the constant reinforcement to the point of tedium drills that shit in, it's probably the most useful aspect of the book because you WILL 100% know how to do what's asked by the end of each chapter, just doing it 30 times in a row in increasingly convoluted ways with intentionally fricked up wording gets tedious.
assembly is the way
c is better for didactic purposes
a typical undergrad cs curriculum has computer architecture, intro to programming (procedural with C and OOP with Java/C#) and then an operating systems class
most of the code you will see in the operating systems books and uni lectures is written in C
Programming is just another skill to conquer. Think of it like walking – you weren't born a master, but with practice you got there. Practice, learn from your mistakes (and others'), and seek to improve every day. Tada! You're now good at that skill. There is more than one path to the top of the mountain, but there are paths that won't lead you to the top. Every one can learn, much like every one can build muscles, you just need consistency, and dedication. In the end anyone can be good at something, but few will be great.
learn how to write Bash scripts
This book is a classic, but for actually learning C I'd instead recommend K. N. King's C Programming: A Modern Approach.
For Python, both Think Python and Automate the Boring Stuff With Python are free online.
I have no strong opinion on the order. In the end, it's good to know both. In fact, to have a good base of programming knowledge, you probably want to be decent in at least one dynamic language (Python, Ruby, or JavaScript), at least one systems language (C, C++, or Rust), and a corporate language (Java or C#).
About learning in general: I'd recommend a mix of highly-regarded books, docs, and lots of practice. The way you level up in programming is by doing increasingly large and ambitious projects. You'll never get good if you do what many IQfy anons do and read stuff, argue lots on IQfy, but don't write much code yourself. But conversely, you can waste a ton of time if you only experiment while never reading anything with higher-level guidance. That's what I did as a teenager; for example, I've spent much effort parsing HTML with regexes and string operations because there was nobody to tell me about DOM, XPath, and recursive descent.
I recommend against videos. Lots of people like them because they require almost no effort to consume while giving you an illusion that you're learning. In the end, the information density is very poor compared to books and blog posts. An exception is recorded talks on highly specialized topics from conferences like CppCon. Sometimes you can't get the information any other way. But that's not relevant to you as a beginner.
Some misc advice:
- Visual Studio Code strikes a great balance between being advanced and beginner friendly
- Once your personal projects are in the mid hundreds of lines, it may be time to start learning git
- You probably want to compile C with -Wall -Wextra
- When writing Python, try to conform to the PEP8 style
the little schemer, literally the easiest programming book
then you can move onto something like sicp or a old college course. which i would recommend if you want to learn to program, due to the focus of these course being to make you able to learn any language afterwards with relative ease.
I'll answer your question with a question OP, if you're just trying to learn more about programming why single out C? be more specific in what you are looking for.
Not him, but C is basically the lingua franca of programming. You don't really need to use it, but knowing it is pretty vital.
I know that. This seems like a XY Problem, I'm trying to untangle it. "I want to learn more." and then immediately wanting to hop into C with a specific book in mind seems odd. Knowing more means I can help more instead of throwing books and languages around aimlessly. That being said, I'll still throw my suggestion(s) in the ring regardless.
https://cs.ossu.dev/coursepages/ostep/
on that site ignore everything until you reach
Extended Approach > Resources > C
found the hyperlink button
https://cs.ossu.dev/coursepages/ostep/#c-1
also just checking out ossu site itself for the first time since i was only interested in this page in particular for implementing a microkernel, it seems they have a full roadmap and an introductory course
Boomping nice thread
Back when I started, some introduction into history of CS and programming was helpful. When you understand how and why all this modern IT shit was created, it will clarify your goals and methods of achieving them.
learncpp.com
thank me later.
I might be dumb. Trying to make C run for 3 days and just get error signs. Specially when I try to use make in the terminal.
What are the errors?
make : The term 'make' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ make hello
+ ~~~~
+ CategoryInfo : ObjectNotFound: (make:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
I'm literally just trying to make a input for simple greeting.
#include <stdio.h>
int main(void)
{
char name;
printf("What's your name?");
scanf("My name is %c", name);
printf("Hello, %s");
}
bait
Looks like you don't have GNU Make installed. If you did unpack it somewhere, maybe you need to tweak the PATH environment variable?
anon, they're on windows, and their code is completely fricked
There is no better way to start your CS journey than Harvard cs50. It's literally free on YouTube.
https://www.youtube.com/playlist?list=PLhQjrBD2T381WAHyx1pq-sBfykqMBI7V4
You can also use the website. CS50 Courses, not programs.
https://www.edx.org/cs50
Vouch
Are you using Windows? Install VS Code and the Windows C compiler, MinGW, then configure the compiler in VS Code. Also install this extension pack: https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools-extension-pack
I think that's all you should need to get up and running. I'm going to bed but hopefully some other anons can help you if you run into any issues. If you're new to programming, it might be a bit confusing to get everything working. Maybe try following a video tutorial on YouTube.
This. It's sometimes cringy, but the information is good.
aside from the featured problem sets, where can I get ideas for simple projects for additional practice?
https://adriann.github.io/programming_problems.html
thanks, bro