Live data from Hacker News

Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

news.ycombinator.com

41–50 of 114 posts

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#41

I disagree with lots of advice here. My strategy to solidify my linux skills was simple: commit to linux desktop. We spend most of our time on our desktop, may as well let that time earn you skill points. I picked ubuntu and use the same on servers. You naturally learn a bit every day through daily use. This really adds up over time without extra effort of using a side system. Getting good at windows or osx is a wast…

It is trendy to hate C now, but if you want to understand a Unix-like OS I think it is mandatory and they go hand in hand. Otherwise, you will have no idea what kind of interface your higher level language is abstracting.

It's ok to not like it, but don't let that dislike be due to lack of understanding.

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#42

Earlier quoted context omitted.

But at some point isn’t it helpful to know that some things are as difficult as you fear, and you just have to power through? I picked up vim early in my programming career and I think it was one of the best decisions I’ve made; I use it every day. Yeah, there’s a time and place for learning “easier” things, but there’s also a time to buckle down, get serious, and dig in.

i am a student and even using nano makes me feel less efficient and productive. is there something I am missing out by not using vim?

It’s hard to look like a true haxxor.

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#43
If you are on Windows I recommend setting up Windows Subsystem for Linux. With VScode. You now have a Linux server with remote code editing. I note you have an Raspberry pi, what follows will work with the pi as well with whatever remote machine. Complete these tasks

1) install the language of your choice and start a simple web site using the languages webserver. View the website in your browser on Windows. A Python Flask 'hello world' or a Node one?

2) Set up an SSH server and remote in from the Windows machine. Learn how to set it up to use keys only instead of passwords. Find out why that is a good idea

3) learn Git. Github has some nice tutorials.

4) set up NGinx to run your website above.

5) set up Nginx for https

6) set up LetsEncrypt.

7) set up a free AWS account, start a server and put your website on it using SSH and git.

8) look through the ssh log files to see login attempts, and the Nginx logs. Imagine there were millions of rows, how would you find a certain one, or the last few? (head, tail, grep, cat).

That should get you somewhere.!

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#44

I disagree with lots of advice here. My strategy to solidify my linux skills was simple: commit to linux desktop. We spend most of our time on our desktop, may as well let that time earn you skill points. I picked ubuntu and use the same on servers. You naturally learn a bit every day through daily use. This really adds up over time without extra effort of using a side system. Getting good at windows or osx is a wast…

Based on personal experience, I can totally echo this comment. I am a business undergrad (senior year), but I am a JavaScript developer for a local start-up. On my Windows laptop, my workflow included applications from MS Office, as well as PowerShell and Vim. At the beginning of this semester, my laptop broke (screen) and I couldn't afford a repair, so I dug up an old ThinkPad T430 that I installed Ubuntu on a couple years back. It was an old machine (2012?) that I bought used, after some searching done on my phone, I upgraded the OS and got to work.

Based on my experience with the switch, I've learned miles more about Linux and how computers work than I would've before. I might even say I like the experience more than I did before. On top of that, as the parent comment says, I've learned more about Linux, shell script, the directory tree, regular expressions, etc., than I think I would've otherwise by self-teaching. It might (read: "definitely will") be uncomfortable at first, but the Linux community is big and helpful and there's plenty of great open-source software that can replace your old workflows.

As far as picking a language goes, I started with Python for the reasons above, but really, starting anywhere is better than being stuck deciding. Common starting points are Python, Java, JavaScript, C#, but really, just pick any language with a large community to help you out. When you think you know enough, consider ideas for a personal project, which is where you'll likely learn the most. After that, keep learning and if you think you want to learn something else, you'll realize how much easier it will be with one language under your belt already.

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#45
There are many ways, but here is one:

Read and lightly work through The C Programming Language (K&R). Code along with the book, don’t feel you have to really deep-dive anything.

You don’t have to learn C well at this point. Just learn from it.

Then start reading The Art Of Unix Programming. Do this casually. Read a bit, code a bit. Between K&R and TAOUP, you’ll be inspired by to write at least two small projects.

To supplement K&R and TAOUP, begin reading Unix Network Programming.

If you have access to a Mac or a Linux machine, explore the man pages.

If you’re on a Mac, explore the man pages __and__ the code that lives on your system.

One way to do this is to use something like vscode’s intellisense to “Go to Definition.” E.g., when you’re coding an example from K&R, right click on one of the included headers, and click “Go to definition.” It will take you to the header file. Look through the code. Then you could look at the code from FreeBSD or OpenBSD on GitHub.

Edit: Just wanted to add, by doing the above you’ll get exposure to your system in new ways. Moreover, you’ll find yourself learning Unix out of necessity, for fun, and by accident. You can practice the art of Unix programming in almost any language at this point. C is unix-y, but so is Rust.

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#46

I disagree with lots of advice here. My strategy to solidify my linux skills was simple: commit to linux desktop. We spend most of our time on our desktop, may as well let that time earn you skill points. I picked ubuntu and use the same on servers. You naturally learn a bit every day through daily use. This really adds up over time without extra effort of using a side system. Getting good at windows or osx is a wast…

> , (5) concise. That rules out C (due to 1)

That's interesting, most people I've started on C have found it easier to start out in that than say, Java, which has been on a hell of a lot of introductory courses for a decade now

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#47

You need a goal which is a tangible end product. Everything else derives from that core requirement. E.g. write a multithreaded chat program with a separate remote backend.

That's way complicated for a newbie project... I'd go with something like a snake game

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#48
I would recommend learning Linux the way I did 15 or so years ago: get rid of other operating systems and use a more 'advanced' distribution (such as Arch or Gentoo). In my case, I fucked up my Windows install on a new laptop when I was 12. At that point, I was stuck and just decided to stick with Linux. It's remarkable how quickly you learn when you absolutely need to in order to use the computer.

My second piece of advice would be to learn C from this book: https://en.wikipedia.org/wiki/The_C_Programming_Language

After finishing it and completing all the exercises, you should be ready to go learn anything else you want to.

Re: Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?

#50
Jump in on the deep end. Install Arch, a tiling wm of some sort, and make it yours. Soon enough you realise this isn't the deep end anymore. You get a lot for free by just using linux every day and dealing with whatever problems might pop up.

Keep the terminal open, if it can be done in a terminal it may turn out you prefer it when you get used to it. Torrents, IRC, playing music, email, file explorer, whatever makes you stay in there. It makes you comfortable navigating the system and you get to see what a GUI hides from you.

Programming? You're not gonna benefit from diving into any deep ends there, continue with JS if that's what you like. Learn databases and web servers, here your new linux skills comes in use. Try some stuff and see what you like.

Post reply on HN