Live data from Hacker News

Don’t Believe Anyone Who Tells You Learning To Code Is Easy

techcrunch.com

81–90 of 186 posts

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#81
post #66

"They don’t tell you that a lot of programming skill is about developing a knack for asking the right questions on Google and knowing which code is best to copy-paste." No, no, no! This always frustrates me. This is not 'coding' (maybe it is, and we should be doing less of it, and more programming). This is gluing together pre-coded snippets and trying to make it work. Continuing to do this is an impediment to gettin…

I copy and paste code all the time. I'm in the business of getting shit done, not learning everything ever, I don't need to learn the ins and outs of some obscure algorithm I'm only going to use once. I also don't need to memorize Apis and boilerplate for technologies I rarely use. Of course once i'm settled into a domain I don't need google anymore. But it's invaluable for quickly diving into new stuff.

[deleted]

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#82
post #77

Earlier quoted context omitted.

please define $$$++?

Well, you take a dollar amount. Then you increase it. Then you increase it some more. Because companies who can afford it will pay you pretty much anything if you can make their whole engineering team even just a few percent more productive by improving the codebase. Or can figure out very hairy issues caused by Daily WTF style situations. For example, I have a friend who sometimes fixes bugs in compiled software run…

Man... can I ask what led a company into the situation where they need to fix software without source code access? Did they rely on a vendor that went out of business? I imagine it is ancient software from the 80's or 90's?

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#83
post #77

Earlier quoted context omitted.

please define $$$++?

Well, you take a dollar amount. Then you increase it. Then you increase it some more. Because companies who can afford it will pay you pretty much anything if you can make their whole engineering team even just a few percent more productive by improving the codebase. Or can figure out very hairy issues caused by Daily WTF style situations. For example, I have a friend who sometimes fixes bugs in compiled software run…

IMO, as it often turns out to be, whether or not the code is copied and pasted doesn't matter by itself.

A competent programmer borrowing code would likely factor it in in a way that won't present maintenance burden later on, and first of all would know when borrowing is appropriate. An incompetent programmer may produce problematic code even regardless of whether it's borrowed or original.

(Though I'd agree that incompetent programmer borrowing chunks of code from different sources without thinking is ‘worse’ than same programmer just writing bad code by himself—more predictability in the latter case.)

In my case, I regularly see borrowed code in projects that I maintain. As long as it's contained in an isolated module, documented (unless it's short and obvious) and used appropriately, I don't see a problem.

Interestingly, front-end code I work on seems to suffer from much worse-quality borrowing—it's like Python people lose all their discipline once they turn to JavaScript.

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#84
post #69
post #66

Earlier quoted context omitted.

I copy and paste code all the time. I'm in the business of getting shit done, not learning everything ever, I don't need to learn the ins and outs of some obscure algorithm I'm only going to use once. I also don't need to memorize Apis and boilerplate for technologies I rarely use. Of course once i'm settled into a domain I don't need google anymore. But it's invaluable for quickly diving into new stuff.

Please never stop doing this. I get paid $$$++ to swoop in after people like you are done and whole teams grind to a halt productivity-wise because the codebase is so bad. You are doing god's work, son. Thank you.

You are being offensive here - going all as hominem rather than actually demonstrating any reason parent comment is wrong.

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#85
post #82
post #77

Earlier quoted context omitted.

Well, you take a dollar amount. Then you increase it. Then you increase it some more. Because companies who can afford it will pay you pretty much anything if you can make their whole engineering team even just a few percent more productive by improving the codebase. Or can figure out very hairy issues caused by Daily WTF style situations. For example, I have a friend who sometimes fixes bugs in compiled software run…

Man... can I ask what led a company into the situation where they need to fix software without source code access? Did they rely on a vendor that went out of business? I imagine it is ancient software from the 80's or 90's?

I don't know the whole story, but seeming as this was banking software I wouldn't be surprised if it was indeed written some time in the 80's or 90's and the original developers were nowhere to be found.

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#86
post #77

Earlier quoted context omitted.

Well, you take a dollar amount. Then you increase it. Then you increase it some more. Because companies who can afford it will pay you pretty much anything if you can make their whole engineering team even just a few percent more productive by improving the codebase. Or can figure out very hairy issues caused by Daily WTF style situations. For example, I have a friend who sometimes fixes bugs in compiled software run…

IMO, as it often turns out to be, whether or not the code is copied and pasted doesn't matter by itself. A competent programmer borrowing code would likely factor it in in a way that won't present maintenance burden later on, and first of all would know when borrowing is appropriate. An incompetent programmer may produce problematic code even regardless of whether it's borrowed or original. (Though I'd agree that inc…

Agreed. I do actually copypaste code in some very specific scenarios. For instance, writing a string capitalization function for Javascript and not needing a whole string processing library.

Sure, you copy paste a line of code after inspecting it, and save yourself some half hour of time on a piece of code that is not core to the problem you're solving.

But I have never seen a programmer who says "I am in the business of getting shit done, so I copy paste code" to produce good code. Anecdotal evidence and whatnot, and my argument could be a bit of a strawman, but this is the sort of canary in a gold mine that I've found.

When a developer on my team says "I just want to get shit done", is when I start preparing for a lot of internal screaming down the line. Happens every single time. Every. Single. Time.

So no, while copy-pasting on its own is not the problem, it is a good symptom to look for.

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#87
post #16

You need multiple things to come together. Some are abstract and general, some are more specific. You need to know the tools you are using, the capabilities of your platforms. At some lowest level it is about solving problems and knowing how to drill down and understand requirements, split a large problem into sub-problems. In that respect it is not unlike an architect or an engineer or carpenter. Then it comes to ab…

"And I have made the that mistake. Friends and family member I have tried to show/teach programming." I'm just curious, knowing what you know now, how would you go about trying to show someone how to program? I may have that opportunity soon and I was going to suggest thinking about a simple yet everyday problem that arises, and try to make it better with an app (could be phone, web app, client app, etc).

1. I try to find out something that the person already understands, so I can frame my metaphors around that.

2. Maybe I'm projecting, but I was tinkering with computers for a long time before I started learning to program. To that end, there's a lot of just intuitive understanding of software that you absorb, basic relationships like configuration files, rebooting, memory, what a browser does, what a URL variable is etc etc.

There's a lot to be said for helping a person round out this knowledge, before you start teaching them how to program.

I don't know that a person needs to know a lot about America before learning American English, but I wouldn't be surprised to find out that it helps. "You see, they're kind of a casual low key people, so their language has a lot of slang and elisions..."

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#88
post #69

Earlier quoted context omitted.

Please never stop doing this. I get paid $$$++ to swoop in after people like you are done and whole teams grind to a halt productivity-wise because the codebase is so bad. You are doing god's work, son. Thank you.

You are being offensive here - going all as hominem rather than actually demonstrating any reason parent comment is wrong.

You missed this part of the post then:

> whole teams grind to a halt productivity-wise because the codebase is so bad

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#89
post #64
post #61

Earlier quoted context omitted.

copy and paste helps to get the job done

I don't think so. A program is an infinite stream of jobs and is never quite 'done'. The less time you spend on keeping things nice and clean, the more frequent the jobs will be. After all, it still needs to be maintained. Unless you are using a library, it's gonna be better long-term going for complete understanding. Even then, it's usually a great idea to understand what a lib does under the hood.

I guess it depends. A freelancer hired through oDesk by default has a clearly defined job and zero incentive to care about ‘nice and clean’.

Sometimes I just can't help thinking that the code I maintain has been optimized, foremost, for someone's job security—even when I know that the author is actually just of ‘get-shit-done’ type, and has been paid hourly.

Re: Don’t Believe Anyone Who Tells You Learning To Code Is Easy

#90

Earlier quoted context omitted.

Uhm, that's how I still learn new languages. Copy, paste, modify just to get something done. The modify part leads to more concrete questions, more Googling, more detailed reading of docs, until at some point I'm engaged enough to go back to zero and actually start learning the language from the basics. (This doesn't work for those languages who's paradigm you first need to understand before being able to do anything…

I mean this in the best way possible, but do you like actually take your mouse over to the webpage, highlight the code, copy it, and then paste it into your editor? I am genuinely curious.

Yes. I do this from time to time. Recent example, wasn't sure what the event was called in JavaScript when the window changed. Couldn't remember if it was resize or windowResize or whatever.

SE had a sample dummy event listener add function, complete with // do stuff here. I cut and paste the whole thing and added what I needed.

I suppose I could've retyped the addEventListener function from scratch but...I dunno, that seemed inefficient. I just needed the name.

Post reply on HN