8 ms·
I pity the student who only knows how to hit the compile button in the IDE and not `javac`. That's a terrible thing to inflict on a beginner, everything will se
by SPBS 5y ago
I pity the student who only knows how to hit the compile button in the IDE and not `javac`. That's a terrible thing to inflict on a beginner, everything will seem like a mystical black box to them with no way forward when they hit encounter their first compilation problem.
- irl_chad 5y agoI’ve been programming in Java for about 10 years now. I would consider myself an expert - I’m not just some guy who built crud apps, I’ve gotten messy with Java. I came up programming for minecraft servers - lots of interesting challenges there. The only time I have ever used javac was for fun. Not once professionally.
- kaba0 5y agoI have yet to write java byte code manually, but a high level understanding of them do make me a better developer in my opinion. It’s not about the number of times one uses it, but knowing about the underlying abstraction.
- FpUser 5y agoI spent bout 3 years in the 90s when I needed to mess with Java code. Would not dream about going through all those giant piles of enterprise code without IDE.
- saagarjha 5y agoIt’s good that we don’t throw people directly into a professional environment when teaching them how to code, no?
- FpUser 5y agoI see no point in wasting time. I learned programming on my own. Started with machine codes. But I grabbed every tool that can help (including IDE) as soon as they appeared. Programming to me was / is a tool I use to make products. I see no point in suffering for the heck of it. Instead of fucking with 10 miles long command line and remembering every squiggly thingy I think it is better to explain to students how computers really work instead.
- saagarjha 5y agoIt's nice to learn how tools work internally, so you can fix them when they break. Once you know how to do that, it's fine to graduate into something that does the work for you.
- ajuc 5y agoIt's not that you need to use it. It's that you need to understand classpath and classloaders to solve some problems. And if you always use IDE automation there's no incentive until it's too late. Stuff is autoimported and autoinstalled. There's dozens of forms where you can add paths to classpaths depending on what button you press to run stuff. It's all magic when it works, and when it doesn't work it's random changes in random places to fix it. There's many more variables than if you just run the compiler from the command line. Good education should give you understanding of the basics, not just higher-level stuff. It's easier to learn high-level stuff when you got the basics down than to unlearn the "magic black box" approach and dive into basics when you need it.
- KronisLV 5y ago> And if you always use IDE automation there's no incentive until it's too late. Too late for what, though? At any point in time there's a certain subset of knowledge that's most relevant that you're trying to do. If it's learning overall programming concepts not the internals of a language which you may or may not use, then NOT using the IDE automation would be detrimental. Furthermore, in every single project that i've worked on professionally, attempting to manually manage dependencies and the way things are compiled would earn me odd looks, since that's far more tedious and less productive than just using Maven/Gradle. Not only that, but manually attempting to manage imports as opposed to letting my IDE do everything that's needed in the background would provide me precisely 0 benefit. In my eyes, "It just works", isn't a bad thing at all, as long as you: - can look into the lower level mechanisms (but only once actually needed) - can find information about all of it, to make the above easier Why would you "unlearn" something if you'll still use it in 95% of the cases, the lower level approaches being the outlier?
- ajuc 5y ago> in every single project that i've worked on professionally, attempting to manually manage dependencies and the way things are compiled would earn me odd looks, since that's far more tedious and less productive than just using Maven/Gradle Of course, we're not talking about doing javac manually when you're working, we're talking about learning the basics before going on to use the automation. BTW Maven and Gradle have plenty of gotchas of their own. If you don't understand what exactly happens you won't solve "magical" problems like old builds of non-snapshot versions remaining in the repo for example. > manually attempting to manage imports as opposed to letting my IDE do everything that's needed in the background would provide me precisely 0 benefit. you say that, and just last month I've had to help a guy manually remove an import of Token class from a wrong package that "magically broke his code" :) > Why would you "unlearn" something if you'll still use it in 95% of the cases, the lower level approaches being the outlier? Because I've seen a lot of people decide something that always worked is not their responsibility to fix when it doesn't work. That's how you end up with 1 guy in the company that understands the build system :)
- lordnacho 5y agoI think I'm in your camp. When you're a programmer, there's a lot of things you rely on that have been done by someone else and you don't really understand, neatly packaged. There's not much point in teaching specific things, because there are thousands of specific things that make a program work. Yesterday my code failed because the whitelist at the server was checking my ipv6 address instead of the ipv4 on the website interface. The day before I was stumped on a Rust borrow checker thing. You end up learning the things that you run into. If you've never needed compiler flags, it's actually not that easy to learn without a motivation. Same goes with memory barriers, garbage collection, and so on. There's just so many rabbit holes. Telling people they need to know this or that is futile, what they need to know is how to figure out whatever their issue is. Some common tools with some common comments about pros and cons, warnings about where the caves are and what's more trivial than it looks. My wife is starting a CS degree, and I'll be looking over her shoulder providing this kind of advice, rather than recommending anything in particular.
- karottenreibe 5y agoWhat sort of compilation problem would that be that's only solvable by manually running javac outside your IDE?
- Supermancho 5y ago> What sort of compilation problem would that be that's only solvable by manually running javac outside your IDE? Figuring out compilation errors when using the configuration of the IDE versus using known system environment variable that are using different values. Notably the resolution of classpaths. The fact you are asking about it, is scary.
- matsemann 5y agoWay to gatekeep, bravo. I've programmed java professionally for 6+ years, never had to deal with that.
- Supermancho 5y agoEven scarier that you have that attitude, given your experience.
- matsemann 5y agoOr maybe you're just wrong? Or maybe I'm out there solving business problems while you're dabbling with your tools?
- approxim8ion 5y agoAll these things are exposed by the IDE if you are willing to look for them. This kind of purism is pointless in my opinion. I did start off with just vi and javac and never complained, but I feel like it's just a matter of knowing the tools you use, even if some of them are an abstraction over the barebones stuff.
- Supermancho 5y ago
- crossroadsguy 5y agoI think it’s time to move on :-) That ship sailed long ago. There’s honestly no need for majority of programmers these days to go cli, vim/emacs way or whatever the one true way is these days. It’s just not needed. And the ones who need it for their work they learn it, know it, and do it. Or for the fun and satisfaction of maintaining, running, and keep oiling something antique and/or analogue.
- kevin_thibedeau 5y agoGood luck throwing CI scripts at someone who can only drive an IDE.
- lordnacho 5y agoEverybody who can code started out not being able to do either of those things. Cross the bridge when you get there.
- crossroadsguy 5y agoI chew CI scripts for breakfast and CD for lunch. Jokes aside, it’s a decent part of my day job and never faced any problem. Neither do my younger colleagues who never ever were even exposed to those esoteric programming thingies. The problem is the belief that cli or mildly esoteric CS practises and skills have to be some kind of mandatory initiation.
- denton-scratch 5y ago> There’s honestly no need for majority of programmers these days to go cli I never did CS classes (I taught a couple once). I agree that you don't need to learn CLI in the first year. The idea that the majority of "programmers" can tackle production code without ever being introduced to a CLI is terrifying, though. I'm astonished to learn that some people think you can get a Computer Science degree without learning processor architecture, IO, operating systems and so on. FWIW, I hate git. It's the devil to learn, and it solves a load of problems I've never had. I wouldn't inflict it on a first-year student. Of course you need to know what a file is to use git; but you need to know what a file is to use any VCS. I don't see how you can teach someone programming before they know what a file is. Is a CS course now little more than a way to get an introductory programming qualification?
- simion314 5y agoI am helping my son to learn c++ for his school clases. This shit that makes sense for us has no fucking sense for a beginner. So for the simple for loop for(int i = 0; i< something; i++){} there is a large number of syntax errors a beginner can do, he can forget to open or close the () , he can forget about the : or placed them in the wrong place, he can forget about the {}. For sure I do not start teaching my son about the c++ compiler, linker though I show him how the program runs in the IDE debugger and how changes update. Low level stuff is needed much later for maybe parts of the students, at the beginning is too much junk that needs to be learned like a parrot.
- WithinReason 5y agoI think you hit the nail on the head. For a beginner learning about a language is so much more important than the compiler, and there's only so many things you can pay attention to at a time. When you're starting it's very important to only learn the minimal subset needed. Later you can expand if you need it, but I have been programming for close to 2 decades and I can count on one hand how many times I had to call a compiler directly. I didn't code much Java though, so maybe there it's different?
- astrobe_ 5y agoI have been programming for 3 decades, the 2 last as a dayjob. It seems to me that there is a deep cultural chasm around the new century. Before 1990 you had next to no Internet and computers were shipped with book-sized printed manuals that were trying to explain how the thing worked, not just how to operate it. After 2000 they begun to come with a single sheet showing how to plug them and www address for perverts who want to download manuals. However it's not entirely a matter of when you started to touch the keyboard. Around me I see "people who understand" and "people who use" of various ages. Guess who helps who more often.
- WithinReason 5y agoIn my experience the people who are helping are the ones who use tools that lets them work more efficiently. They have more time to learn new things, while the ones who use less efficient tools use much of their mental effort on the tools themselves.
- agumonkey 5y agoI'm viscerally into this camp. I just cannot fathom using black box. I went to college to engineer not to reuse, at least not blindly. And things like eclipse have just too many layers and principle-less helpers. Even when an intern, we had to make tiny eclipse wizards (that didn't add anything of value, just cute helpers ala visual studio to setup some files) I was physically unhappy because it's the opposite of how I'm wired. Whenever something doesn't go your way.. well you're back to square one, having to understand java, javac, the jvm AND eclipse stack and logic on top.
- agent327 5y agoDo you have any clue how many layers there are below the java/javac layer? What made you decide that that particular layer is where it's at, and that just one layer up everything is bad?
- agumonkey 5y agoGood point. Somehow the compiler is the critical tool, eclipse was failing to provide value while impeding me to work too early for me. I was happier with a makefile most of the time because I had the information in short form under my eyes. With the jvm you have a spec, it's somehow meaningful, Eclipse APIs were quite horrendous and if you need to go that low to understand why your project fails to run it's not a good tool.
- agent327 5y agoI completely understand that. I'm not a java programmer; my experience is limited to fixing one tiny bug, in one java program, and I struggled a bit with Eclipse before realising building from the commandline was also possible and pretty simple. But I do most of my work in Visual Studio, which I prefer over vim+make+gdb because a powerful IDE does give you a significant advantage over a 'mere' text editor. I also find that working in vim imposes a much higher mental load than doing the same in MSVC (and don't get me started on vi without the 'm'...).
- 5y ago
- faizshah 5y agoI completely disagree, when I was a beginner programmer my only concern was “how do i make games?” i didn't really care about the game engine, the compilation process, the algorithms even, my focus was on making a game. From middle school until early high school all my coding was in IDEs and I never really tried to use the command line it just wasnt my concern, it was much easier to hit the green run button. Throughout that time I was learning all the basic concepts of how a program is executed, what is control flow, how do you write good code, how does the program even run (i recall one time in middle school trying to figure out if all the lines in a program run at once or in sequence), how do you simplify booleans, how do you debug etc. It was only later once I was interested in web development that I started picking up linux, learning more deeply about the compilation process, learning algorithms etc. For a beginner all that stuff is just more roadblocks to building your interest and foundation. But later I started hitting a wall when trying web development or 3d game programming where I didn’t have the fundamentals and thats when I started learning all the other skills besides just typing some code and hitting the green run button. In the transition from beginner programmer to Intermediate programmer is where I would say one should learn the behind the scenes concepts not while you’re still building an interest and foundation. Also interesting aside the programming environment I started on was called “Kids Programming Language” it was like a kind of simplified blackbox environment that I compared to flash (but didnt cost money). Even today I prefer to introduce coding in such blackbox environments like processing.js maybe because of that.
- edave64 5y agoYes, what a pitty. They will have to read that compilation error from the IDEs "compile" window and not the console. Or just see the red squiggly lines in the code. That is a problem for some reason. And you know what happens when people use a black box and that stops working? They start learning how it works then. When it has actually any relevance for them. Until then it's just a more complicated way of doing things that doesn't benefit them in any way whatsoever.
- alpaca128 5y ago> people use a black box and that stops working? They start learning how it works then. No, they don't. Because they don't even know where to start. They never learned anything outside of the compile button and the project settings. I know because I was in that boat once. Nothing ever boosted my programming skills more than learning the basics or another layer of what's actually going on behind the abstractions. You also need to consider hardware. School computers are not very good in general. The one I had to use for Eclipse took at least 2 minutes to start the IDE until it reached the point it actually reacted to mouse clicks. You can guess how fun the rest was. But I didn't even consider using a lightweight tool back then. Why? Because the only editor I knew was Notepad, and nobody would use that voluntarily. And nobody taught something other than fat IDEs. There was a time I'd programmed for over a year and could not code in languages like C because the program didn't have a Compile button. It was confusing and I gave up. You underestimate how bad an IDE-only approach to teaching programming is. It comes with batteries but also learned helplessness included.
- approxim8ion 5y ago>No, they don't. Because they don't even know where to start. They never learned anything outside of... This is fixable though, instead of just telling them to use the tools you can teach students how to use them well. It also doesn't hurt to inculcate a mindset that shows them how to look for help when they are stuck. Discarding the IDE entirely is like throwing the baby out with the bathwater in my opinion.
- 5y ago
- IshKebab 5y ago> everything will seem like a mystical black box The whole reason computers work at all is because of the many many layers of abstraction. At some point everything seems like a mystical black box to you too. Sure it might be at a lower level. But there's always a point where you get to "I just do this and it does what it says it should. I don't understand how it works." Do you feel like a terrible thing has been inflicted on you because you don't know how the Linux kernel works internally, or how `idiv` is implemented, or which SRAM cells your CPU uses? You have to stop somewhere, and running javac manually is something almost no Java developers do so learning it definitely seems like a terrible thing to inflict on beginners.
- cerved 5y agoJava is a terrible thing to inflict on beginners
- irl_chad 5y agoMy favourite programming language is supreme because of some objective reason and totally not because it’s my favourite. Yeah we’ve all heard that one before
- IshKebab 5y agoHard to disagree with that! Though it does have some redeeming features: it's statically typed, runs pretty fast, has absolute rock solid code intelligence (the best of any language in my experience) and a ton of learning resources.
- cerved 5y agoUnfortunately it's ridiculously verbose and static typing isn't inferred.
- jcelerier 5y agoI pity the HN commentor who only knows how to hit the "power on" button on his computer and not how the CPU will actually power-up and start running instructions.
- yeputons 5y agoEverything does seem like a mystical black box with no way forward when you're just getting started. Does not matter if it's GUI, CLI, IDE or a raw compiler. What is `SyntaxError: invalid syntax` for `print(hello world)`? What is `NameError: name 'Print' is not defined`? I don't have any names, I just want to show a string. The only differences are: a) amount of new things to learn (e.g. students already know how to use GUI, but learning CLI is a whole separate skill); b) quality of the tool (e.g. how relevant/readable error messages and configuration are); c) your ability to get help with the specific tool you're using. You have to stop digging into details somewhere. You can always go deeper, if you want. In my opinion, it's perfectly reasonable to learn one thing at a time. You can start with learning CLI and then learn Java using javac. You can also start with learning some IDE and its build facilities and use Java completely inside it.
- in3d 5y agoSarcasm? I hope?