Step 1 in being a developer: Make a thing that sucks

Step 1 in being a developer: Make a thing that sucks

Here we are at day 3 of my articles on becoming a developer and yesterday I said that I was finally going to get down to coding and write about variables - global, local, string, numeric - but now I'm not.

I'll tell you two reasons why. First, because I tried learning R that way. I started a course and read a book, by someone who was supposed to know all about computer science and R. It was a complete waste of my time. There was a whole chapter on data types and another whole chapter on data frames. But, what I wanted to do was analyze some data. Second, even if I had managed to make it through all of that without dying of boredom, I still wouldn't have been able to program in R.

Knowing the statements and rules for a language doesn't make you a software developer any more than speaking English makes you a novelist

I know a lot of English words, most of the rules for grammar and punctuation, and, yet, I am not a screenwriter.

So, you want to be a developer? Make something.

Oh, and your thing will suck. I can say that with certainty, even though I know nothing about you, because everyone's first version of everything sucks.

What should you make? Well, it may come as no surprise to you that I have some advice on that. Your thing should be harder than just programming "Hello, world" but not so difficult that you won't be able to do it in a relatively short period of time. My suggestion is that your first thing should take somewhere between a week and a month of your spare time. It should be complicated enough that you make mistakes and swear a lot and interesting enough that you want to finish it.

There are two ways to make your first thing. Neither is the correct one and it will suck either way.

  1. Find a book or video that teaches you to code. Do not just start coding! Write out what your program should do. This can be pseudo code. It can be a flow chart using those symbols in PowerPoint that probably only the .003% of the population who took programming courses in the 1970s actually recognize. After that, start writing your thing.
  2. Find a program in a book or online, copy that program, line for line, and get it to work. Then, edit to be what you want. Yes, you will hear a lot of people groaning about "copy-pasta" and yes, this isn't what you want to be doing ten years from now, but if it works for you, it is a perfectly fine way to start. (Day 4 article is on exactly this.)

Funny thing, the memory game above was one of the first programs I wrote. I found it in a book on games with JavaScript and HTML. Fast forward nine years and I realized that I could write it much better than the book's author had and I completely rewrote it.

Okay, I will say something about variables ...

As you work on your thing, it won't work and that is how you will learn to be a developer. You'll get an error that says something like "ERROR: Variable grade in list does not match type prescribed for this list." or "Frank is not a number" . Now, you will remember that there are string/ character variables and numeric variables. You might discover that JavaScript is dynamically typed and will change the variable type as needed, even if that was no what you had in mind. Other languages will not change variable type, so if you had defined age as a character variable, even if age is entered as a number, you'll get an error. This sounds like a bad thing but it's probably not because it prevents you from doing stupid stuff like finding the mean for race when it is entered as 1=African-American, 2 = Asian-American and so on.

Things to make - three better ideas than a tip calculator

I've seen a program to calculate tips given in several places as an example of a first project. I disagree with that. A. Not everyone lives in America, so many countries don't have tipping. B. Tipping is easy. If you live in Chile, it's 10%. Look at the bill. Move the decimal. Give that. In fact, waiters just say ?Incluye propina? and you say, "Sí" so you don't even need to do that. If you live in the U.S. , take 10% and multiply it by two. Done.

Your first thing should be something you want to finish. Here are three ideas I've seen get a lot of people started:

  1. Analyze some data to answer a question you wonder about. This is how I got started. There are an enormous number of things I want to know (my children would say I'm nosy), so being able to read in data and answer the question about, say, prevalence of deaths by heart disease among different races was a motivator for me.
  2. Make a game. Lots of people start this way. Don't start trying to make the next World of Warcraft. Make a memory game, a simple maze, a choose your own adventure graphic novel.
  3. Create something useful for you. I knew someone who taught himself database programming because he had a large number of videotapes (no, not the bad kind) and he never could remember which ones he had or where they were. Now, I'm no more likely to do that than alphabetize my spice rack, which I also don't do, but it was a problem for him that he wanted to solve.


要查看或添加评论,请登录

AnnMaria De Mars的更多文章

  • If you think you don't need to comment your code, you're wrong

    If you think you don't need to comment your code, you're wrong

    There are some tips I have for new developers that may be open to debate or matters of opinion, but on this issue, you…

    1 条评论
  • Numeric functions and missing data

    Numeric functions and missing data

    Last time I talked about how useful character functions are. This article is in memory (although I don't think he's…

  • Developer Journey: Learn Character functions

    Developer Journey: Learn Character functions

    A few days ago, I wrote about programming for things you think will never happen, because you are wrong. Here is…

  • Developer Journey: Copilot could be your friend

    Developer Journey: Copilot could be your friend

    I only appear to be a hypocrite. TL; DR; Copilot is unlikely to be the best choice if you are working on a complex…

  • Developer Stories: How to screw up If-then-else

    Developer Stories: How to screw up If-then-else

    Since it's been a couple of days since I actually talked about code (the last time was arrays, if you are keeping…

    1 条评论
  • Developer Journey, Day 7: When in doubt, draw it out

    Developer Journey, Day 7: When in doubt, draw it out

    I suck at art. People say you cannot fail art but I am living proof that if you are really, really bad at it, you can…

  • Day 6: Learn to love arrays

    Day 6: Learn to love arrays

    In my last post, I talked about pseudo code. Today, I want to look at some actual code.

    3 条评论
  • Day 5: So you want to be a developer

    Day 5: So you want to be a developer

    Yesterday, I said it was fine to start with copying and pasting someone else's code as long as you learned to read it…

  • Copy-paste vs learning to read code

    Copy-paste vs learning to read code

    As a beginning developer, you may hear more experienced colleagues sneer at "copy paste" programmers. While they are…

  • So, you want to be a developer. Step 0b

    So, you want to be a developer. Step 0b

    Here we are at Day 2 of my series for wanna be developers and we're not to coding yet. That's why it's still Step 0.

社区洞察

其他会员也浏览了