Blogger Widgets

Sunday 30 June 2013

My five quick tips for #Beginner Computer #programmers- #Programming

image



Today I’ve just decided to converse/talk/blog; just decided to give it to you right quick. Just read through, may help a brother or a sister out there *Giggling* of course I will be blogging about technology {Programming} let’s not get sentimental here =)
I want to give my first five quick tips to everyone who is starting programming to kind of get a general sense of what it is {am so not keeping count, am writing this straight from the brain, if they are more or less, just embrace it *Grinning*}. I only knew about programming when I got hold of a programming e-book. Like most of you who got to hear about it and learn it in college, on my side that wasn’t the case. I had to learn it on my own. I didn’t like how I was being taught by most of the e-books as in they were teaching you certain computer programming languages but they weren’t teaching you the concept of what programming is in general(am so sure this happens in colleges too).
My first quick tip is this: don’t look at computer programming as a set of commands or functions, look at it as a problem solving tool, that’s all it is. You are just trying to solve a problem and you have a tool that allows you to solve a problem, that’s all it is, look at it as a problem solving tool and when you look at it that way then later on when you know let’s say five programming languages then you will be able to choose a specific one out of those five to solve each specific problem because different problems require different types of solutions. One type of problem needs more speed, another problem needs a different type of sorting algorithm and different programming languages have different functions for those. Some will work faster, some will work slower so once you look at it, just look at it as a problem solving tool.
Second tip is that: you shouldn’t mix; you should start with one programming language and stick with that. I would personally recommend you start from C++, that is what I did but you can really start from anything you want: you can start from visual basic, you can start from PHP, you can start from anything and C++ is just my preference. I think it’s good you start from that because it’s pretty challenging and you learn all the basics, all the fundamentals stuff like the pointers and everything else and that is good; for me it was good. For you it might be better to start from Java *Smiling* I don’t know but the bottom line is this-you have to start from one programming language and don’t incorporate everything else together cause that is just going to confuse you. You’ve got to learn the syntax of one programming language, learn all the functions of it and how it works, get a general sense of the whole thing. I’d say dedicate at least two years, *runs fingers through the hair* okay at least one year but I’d say two years, dedicate it to one programming language so you know it fully. Once you do that then you can move to another programming language. That’s what I did when I was finished with Java I moved on to PHP I think and it took me a month to learn, to just get a sense of how it works, just to learn how it function, tracks and how to make the variables plus all those small stuffs. The reason is because I already knew the concept of programming and besides I was already comfortable with one programming language. The thing with programming is that all programming languages is that they share a lot of similarity, I mean there’s different syntaxes, there’s different functions in this and that but most of the stuff is very similar, so once you learn one language, learning another is not that difficult; so definitely do that.


image



Third is: Please keep your code clean. There is a tendency, when I was starting the program; there is this tendency to over complicate code because in a way you want to write a lot of code {you get excited ““OOo0oHH””I just want to with a lot of code}, it’s good in a way cause that means you’re passionate about it but what’s bad about it: you end up with a SPAGHETTI CODE. A spaghetti code is very difficult to understand at the end, when you write a code and you try to come back to maintain or debug or do whatever else you want with the code, it’s very difficult to do that. Try to keep it very clean, by clean I mean use understandable variable names but don’t make them too long, your function names once again don’t make them too long, it should be like this: when you’re looking at that page, you shouldn’t be scrolling to the right all the time, what I mean by that- it has to be short because sometimes you know you have this conditional statement which goes on and on, you have to break it down. If something is too long you have to break it down, if something is too complicated, you have to break it down. If you see something is getting way too complicated, you have to break it down, that’s rule thumb, you’ve got to think of another way to do it because if it’s really that complicated it: its to come back at you later on when you’re trying to debug it or connect it to another program or whatever else you are trying to do.
The other thing I’ve got to tell you {Fourth tip}, a lot of the beginners don’t test their code before moving on, what I mean by that is this: when you are writing a couple lines of code, please test it, please debug it, please makes sure it works{You will thank me later}. Here is what happens, you write a code, you think it works *smirking* you are confident that’s going to work because you think that’s what you wrote but there is so many times you write a code that you meant to do something but actually does something else. Later on you find that out and it takes you so long, it’s a tedious process. It’s a tedious process because you haven’t checked it when you wrote it so every time when you’re writing a couple lines of code just go over make sure it’s right, debug it, and test it. This is important especially when you are doing a huge project and it has like thousands line of code, at the end imagine there’s a little syntax problems or ideological problem it’s going to very difficult to find later on. ~Write and test ~Write and Test ~Write and Test~ with experience you might write thirty or forty lines of code before testing, not that because you are confident, you are sure because you have done it so many times.
The very last tip is this, this is not really for beginner computer programmers, this is really for people who are trying to make a decision if they should get into programming or not, so here is my advice {this goes beyond the scope of programming, it relates to life in general} but I will say this if you don’t love programming, don’t get into it-Am neither being rude nor mean here, am just trying to save you money and time. Students drop out of colleges and universities, the reason being that they thought that programming; they heard from someone that computer programming/computer engineering brings you lots of money. Students drop out because they can handle it; the reason is because computer programming is not like in the movies where you type a couple of “things”, then break into their system and get all the money *Giggling*-It’s not like that I mean, it takes a lot of time to go over a code, to think about the problem, to plan it out then write a code, go over it and make sure the code is clean. It takes so much patient, it takes so much time, it’s overwhelming at times; you have to really love it. You have to really love, not programming but problem solving in general, you have to love it in order to enjoy programming, in order to get a job and not get sick of it after like *grinning* forty years you know, be able to constantly develop and that is only going to happen if you love it. As I say it goes for everything, money should be your reason.
I know I said I was going to give you five tips, and my last one is really important. When you read a problem don’t just jump into writing the code; it’s not right, I mean it’s always going to fail you and you always going to get mad at the end {I have done that; it’s not good}. When you’re reading a problem, try to understand the requirements {I know it sounds very cliché but you know this is true}, when you get to the problem try to understand the requirements, try to understand what it wants. Draw a chart, try to see the data flow where one thing flows and where it ends up, how does it change, you know try to connect them; try to see it on your mind. Try to plan it out, see it very clearly. Once you have the solution on your mind, you know exactly how to solve it, and then proceed to programming it. You see if you don’t do that it’s going to go back to messy code; because you are going to be solving it as you are writing it and that’s not good, you’re kind of winging it, that’s not good, that’s not planned. You have to plan it first because when it’s planned, then you’ll have a much clear code, much organized code and it will work and that’s really the most important thing.


image

No comments:

Post a Comment