Honestly, it isn't hard. Go follow a tutorial on writing some JavaScript, you need essentially no tooling and can write some happy little functions fairly quickly! It's a bit of a rabbit hole, but feel free to PM me if you have questions!
Edit: This has gotten a ton of traction!! Kudos to the guy who just said "No."
There are a lot of opinions floating around. Unless you are jumping the gun to go straight to university for programming, don't start with C. I primarily program in C++, Python, and JavaScript (specifically Nodejs).
Both JavaScript and Python are excellent for beginners. All these people with a ton of experience programming forget how unforgiving C#, Java, etc. Can be for someone totally green. I am talking about writing your first loops, hello world. Writing a script that runs infinitely and prints that your best friend is an idiot to send them a video of over social media. That is the kind of stuff that gets people to ease into it.
Regardless my offer still stands to help if you like, and I hope these goons haven't scared you off at the "choose a language to learn" step.
No, if he wants to learn how to code he should investigate non Web languages. They're super inconsistent especially with javascript callback hell. As a starter he should focus on variables types, basic logic and some oop principles. I'd suggest C# and python. Ideally I'd suggest C but most beginners will lose interest very quickly
C# is my favourite language so I might be biased but C# is not really that hard. Sure, it's not Python, but it sure is a lot easier and more high-level than C...
That's exactly the problem. It is so high level that a begginer just starting out is probably going to be confused by classes and the such. Imagine trying to explain OOP to a begginer who doesn't even know what a variable is. I know that you can ignore those things, but I feel the language is ill suited for teaching.
Eh, I mean they used to teach students C++ for coding and now it's usually Java or Python.
My first language was C# and I honestly recommend C# as a starting language. While python is cool for quick scripts and automation and stuff I think C# gives you a better ground knowledge programming as a whole and is still pretty easy.
Ahh yes I see your point. Even if someone could understand classes fine like I did, I had a really hard time at first understanding generics and delegates and interfaces and polymorphism and... Yea maybe beginners should stick to Python.
You don’t have to understand polymorphism to use C#. In fact I’d bet a large number of junior devs couldn’t tell you what it is. I always include a question about it in an interview; because it’s a useful indicator of what level of serious they are about OOP, and more importantly, if they don’t know what it is gives a good indicator of how honest they are when they don’t know something. Honesty and being able to admit when you need help or don’t know is a big positive for a new hire.
TL;DR you don’t need to understand OOP to learn to program in C#. Understanding that a variable is a thing might be useful though, especially in this code block ;)
My first language was Java and I think that while it suffers from the same types of problems as C#, it suffers way less. Not nearly as much worrying about nullables or delegates or operator overloading or weird syntax-breaky statements like LINQ. Java is much more barebones and I think that helps make it somewhat more learnable. As always tho I'm biased bc I dig Java
I'm opposite, but it's probably cause I learned C# as my first language and Java in college. Honestly, there's so many cases that I can write a lot cleaner and sorter code in C# than in Java. I also like being able to use 'var' as well.
But overall I just find it easier to read. For example, using the random class to spawn a number between say 55 and 121. Assuming we have the import statements in both in Java it would be
Random rng = new Random();
rng.nextInt(67)+55;
while in C#:
var rng = new Random();
rng.Next(55, 122);
I just find that a lot easier to read personally and it's not only the Random class, but a lot of methods in C# that just feel cleaner to read. But each their own.
It really doesn’t matter what language you start with. There’s really no wrong way to learn to program. All you’re doing is learning how to interact with a computer in a structured way. Learning JavaScript is a great idea because there’s minimal setup, there are tons of educational resources to reference, and you can get something up and running quickly.
Telling someone that the only good way to learn to program is by first applying themselves and learning ‘logic’ is nonsense. People learn to program by trying it out. It’s not rocket science.
Yeah, I like a lot JS (no hate please lol), but it's quite quirky (with its prototyped classes for instance), it's better as a second or third language. It's true that it requires no tooling, so it might be interesting for an initiation, but if you go deeper than that all its quirkiness shows up.
I'd advise Python as well, and I can't find any language that I know and that is as easy to learn as a first language. I don't know much C# btw, but I won't advise a strongly typed language as first language. I'd rather go on a weakly typed one and then learn that there are strongly typed languages and why so.
I think C# and Java are fine as first languages. They are easier than C or C++ for sure, but still give a good grounding in programming.
I think it really depends on what the person wants to do with their skills. I'll recommend python if you want to make scripts or don't really know what you want to do with it, but if you wanted to say, make a game at some point, I'd probably say just bit the bullet and start with at least C# if not C++, because as an indie dev, making a game is difficult, so if you can't overcome learning a harder programming language, you're probably not making a game.
Hey true. It is just that I got discouraged when I wanted to learn C++, although I already knew a bit of coding (I was already making Minigames on my calculator). I wanted to go too fast and ended up not liking C++. So my advice would be don't go too fast and try to skip too much steps. And I find that Python is a good fist step. (I still don't like very much C++ btw, even though I like C.)
If all you wanna do is make a game, there's the option of Unity or Unreal Engine, although I didn't try so I can't tell advice on these ones.
But in the end, we all are different and all have different paths. I would not recommend my path so I can only imagine what I'd prefer, but in the end everyone builds it's own path.
I do use unity for my game I’m developing now mainly cause I like C# better and I think unity is the better engine when it comes to 2D games.
But yeah I do agree. I think a lot of people hope into coding with a huge end goal and get overwhelmed because they didn’t realize how long the journey to that goal was gonna take
I wouldn’t say it’s really different, but of course working inside a game engine is going to be different than working outside of one.
I use C# outside of unity to make personal windows applications for myself and friends. Like compiling Skyrim special edition mods for a modded switch, for an example.
But I do get what you mean, the biggest difference is just working with the code updating every frame and the unity API for sure. Currently working on an indie game in unity for the past year, it’s been fun though.
Callback hell isn't much of a thing anymore now that we have promises, and a lot of the strange quirks of Javascript are things that many tutorials and guides will try to prevent you from using from the very start (like showing let/const instead of var).
I learned to code in html+css+JavaScript with some MySQL and PHP for 2 years before finally moving on to Objective-C. Learning objective c wasn’t that hard because I already had the logic built from JavaScript, though understanding OOP is a whole nother discussion. After high school I went to Carnegie Mellon University where I graduated with a CS degree. It doesn’t really matter which language you start with. A lot of the understanding is transferable to other languages.
101
u/Big16th Apr 24 '21
I wish I knew how to code