I’ve taken three years of computer classes at my highschool. One of them was not programming related, but was offering more of a collective computer experience, like getting familiar with OSX shortcuts, working with photoshop and designing web pages (with technology from the early 2000′s). My first class was of course Introduction to Java. It was a basic class that got everyone up to speed on syntax: variables, control structures, iteration and basic classes and just maybe, arrays. Half a year should be able to contain more content that that, but overtime, the class was definitely refined. Last year, I took the AP Computer Science course at my highschool. I don’t know the results from my exam in early May yet, however, I believe they’re decent.
I was a different beast when I walked into that AP Computer Science course than the other students, I already knew a lot. But it isn’t an essential requirement to know a lot. You can have never programmed a single day before in your life, that’s fine. But there are things you need to know, before you can start learning the material for AP Computer Science and beyond.
Thus, I present my top 5 tips for new AP Computer Science Students!
5 – Computer Familiarity
This is probably obvious, but you need to know what kind of computer you’re going to be using when you actually start programming in class. If you’re using Windows, OSX, or some variant of Linux, you need to know how to use that system. You don’t need to be a genius with the system, but you need to be able to install things, navigate around the filesystem, understand how paths work in the system (like where the root drive is, i.e. c: or /).
Why is this important? It saves time. You’re learning specific material, but not about computers. A lot of instructors, when using computers that students aren’t familiar with (Macs) have to spend valuable time teaching the basics of the system. Don’t let that be you. If you’re not familiar with what you’ll be using, find out what it is, and then find someone who has a computer with that OS on it, and go play with it.
4 – Go fast and then slow down
Honestly, there is no better title for this one.
If you’re given a programming assignment, step back for a moment. How much time do you have until you need to turn it in? How much work will it be to code whatever it is? These determine your programming schedule. If you have the time, and the program isn’t overly complex, do the following: complete a working version of the program as quickly as possible, then do it again, but with optimizations you could apply. Optimizations, although you may not know what they are right now, may be: abstracting classes, extracting repeated code into methods, one-lining variables, making more elegant loops, eliminate needless if/else structures when a different boolean modifier will do and so on. Anything, basically, to make your code smaller, more readable and more elegant. This will make you a better programmer.
3 – Read code
After a month or two in your class, look back on the early programs you wrote. See if you giggle and snort when you read them.
Like my #4 tip, you should try to rewrite your old programs to make them more elegant, shorter and more readable. You’ll understand how this works as you go through your class more and look back on old work.
You should also be reading other peoples’ code. Why? Because it gives you the experience of seeing code you did not write and had no control over. It allows you to experience someone’s train of thought when they were working through the program. It gives you an idea of other solutions, other methods and conventions. It lets you be introspective too, it permits you to see how you think compared with that of another.
2 – Google
Lousy title? No.
You’ll be faced with things you don’t understand in your class. Everyone is expected to ask questions about those things. However, Google is much better source for answers, some of the time.
If you’re getting a syntax error, google the speicific meaning. If you’re getting a special exception error, google it. If you want to know more about a specific package in Java, google it. If you want to know _____, google it (see the blank I left for you, fill it in.)
Google is a wealth of knowledge just for you. If Google some how fails to provide a good answer, then, ask your instructor. Googling independently. is your goal, where you find answers and solutions on your own.
I cannot stress this enough. If you don’t know something, Google It.
1 – Buy a book
If you’re reading this before your class starts, you’re in luck because you can actually do this.
You need to buy a book. What book? A book that teaches you about Java. Here are some suggestions:
I seriously don’t care if you already took an introduction class with Java or programming. You need to self study Java over your summer vacation (or until whenever your class starts).
Why? I’m adamant about this because I went through the first of many iterations of an Intro-To-Java class, as I mentioned earlier. The first time, it was more about coding. Then, it was making little games with greenfoot, then it was a introduction with scratch, then coding, then greenfoot. Your class may have missed something (or a lot of things), so you need to get ahead. I was lucky, I knew a lot of programming before I got into Java. If you don’t though, you’ll need to get all of the basics, the things you need to know in order to use the fancier features of Java, but the things your instructors don’t mention to you in your introduction class.
I’m probably not taking another CS course until college, in fall of 2011. I’ve taught many people things in programming that they would have never been exposed to if I hadn’t done the things I’ve written above. Yes, the things about are things I did, and I believe those things made me a better programmer and a better student.
So, in short, good luck with your AP Computer Science class.