Thursday, December 21, 2006
By John, Annie, Lucy and the Woof-Woofs at 10:33 AM
Ok not really. I'm putting in about 52 hours between both jobs this week and it'll be a steady 40 after that till school starts. And yet this has still given me some time to myself, the 20 minutes I spend in the shower each morning. Which had previously been given to homework problem solving during the semester.
Due to the lack of my friends updating their blog or not having one at all, I've become bored. So since I'm bored I'm going to bore you with some details of my life. Aren't you special?
A couple of days ago Jon, Nate and I were talking about goals for the end of the year. I decided that I don't have enough(read: any) free time between now and then so I decided to extend my goals accomplishing period till the end of my winter break. Which just so happens to be January 15th. We all decided that more time dedicated to the mod was important, and thus I have been working up some goals that go right along with getting that all important goal on track. I guess I can list them out for all ya blog readers.
- More time for the mod. (duh)
- A few mod related things that I need to do are to get out my C/C++ books and brush up on my C/C++ syntax. I also need to get Hammer, and the Source SDK installed and working. Then it will be on to some research on how to get started with this mod.
- Reformating the main pc. I'm going make it a dual boot between WinXP(50GB) and Ubuntu(30GB). Windows for games and Mod work, and Ubuntu for everything else.
- Clean up various parts of my apartment. I need to clean up some stuff in my room and rearrange my book shelves.
- Setup one of my pcs as an Ubuntu Server for things like Apache, PHP, MySQL, SVN, Vent server, etc. There is an extremely slight chance that this could turn into a file server in the future.
- Get books, folders, and notebooks for the next (and final!) semester of school.
I have gotten a bit of those finished. I have cleaned up part of my room and organized one of my book cases. I also reformated my main pc last night and started installed windows on it. I hope to have the programs and most of the games finished up by the time I head to job number two. With any luck I'll have the pc totally restored and the cleaning done before I head home for New Year's Weekend. My plan is to set up the server and the mod stuff once I get back. With the first of the year here my hours and Dillions should be cut back and maybe I'll only be working 35 or so hours a week.
A goal I plan to do through out this next semester is one I keep telling myself that I'll do every semester, but I figure that since it's my last I should at least try it once. I will stay on top of my homework. I will start if not finish it on the first free (non-Dillions work) night after I get it assigned. Hopfully then I can avoid the hell I went through the last two weeks of this past semester. I also think only have one programming class instead of four will help as well.
I remembered to check my grades yesterday and I managed to pass all my classes, even the databases one that I had the crappy project to do. I ended up with 3 B's and a C. Not as good as I would have liked, but I passed and my GPA stayed about the same so I'm not complaining too much.
I guess I had better get some work done. I could sit here and bitch about people and how they suck. I even had a whole rant lined out instead of this entry, but I ultimately decided that its life and I'm just going to have to get used to it if I want to be in this line of work.
Side Note: If a person who writes a blog is a blogger does that make those who read a blog bloggees?
Thursday, December 14, 2006
By John, Annie, Lucy and the Woof-Woofs at 11:18 PM
Disclaimer: I could be way off base with some of this, but for the most part (if not all) this should be accurate.
Here is an article on some data structures that programmers use. I'm writing this mostly for Jon's homework assignments that I'm giving him. To most of you you'll probably find this to be boring and really not useful, but that is what most programming articles are, boring and useless. So here we go.
In this first article on data structures I'm going to cover three of the more basic structures that programmers use. They are the ArrayList, Linked List and Stack. A few that I hope to get to in a later article are the Heap and Binary Tree.
Background
We'll have to cover some back ground first. I'm talking about Arrays, and I'll give a description of them and their uses. Most people know that as a programmer you have a few different types of information that you can store (i.e. integers, floating point numbers, characters, etc.). Well what if you want to store 20 integers instead of just one? You could declare 20 different int variables and store them one by one. But this leds to a couple of problems.
- The first being that really its just bad programming style. If you have 20, 30 or even a 100 variables in your program (one part of it) you've done something wrong. This will lead to messy and inefficent code. You'll have to spend extra time trying to figure out where to use what variable and just have that many more lines of code to go through when you debug your program.
- The second and more important of the two problems is that it isn't as effiecent. When you declare 20 variables the program will allocate the memory for those where ever it can find a spot. So you can have 20 different numbers stored anywhere in the footprint of your programs memory. This can lead to increased time in execution or even a bigger memory footprint. Lets say that an int takes up 1 byte of space(in reality most ints take up 4 bytes). When a program allocates memory for a variable it grabs the first spot that can fit it. If this spot is 1.5 bytes big the int will fit just fine, but you now have 0.5 bytes wasted in the memory footprint. Not much I know, but imagine it with thousands of variables doing this for a bunch of different programs. It adds up.
Arrays are nice to store large amounts of similar data. The only problem is that they have to be declared statically, meaning that their size can't change. To get around this we have a few different datastructures that we can use. I'm going to talk about three of them here (and maybe more later on).
ArrayList
An ArrayList is just an Array that can grow(hold more data). Most languages come with them in some form. Most main stream languages have them in their standard library. Java and C# have ArrayLists and C++ has Vectors. Using Java as an example, it implements an ArrayList as an object. And doing so it has allowed for them to create several extra methods to use on it. You can insert in the middle instead of just at the end, as well as remove from anywhere in the list. It also has a few other nifty methods associated with it, look them up in the standard library.
Linked List
A Linked List is similar to an ArrayList. The only big differece is that an ArrayList is made up of an array and when that array gets full it creates a new, bigger array and copies the information to the new array. A Linked List is a line of Nodes. A Node holds some information and a pointer to the next Node in the list. So doing things like removing a Node from the list is easier since all you do is take the pointer that the previous Node has and set it to the next Node in the list thereby cutting out the middle Node. The methods that are usually associated with a Linked List are the same as an ArrayList.
Stack
A stack is a bit different that the other two I talked about. It can be implemented as either an array based or as a linked Node based. Stacks are much simpliar that the other two. They have to main functions, Push and Pop. To add something to the stack you Push it on. It goes to the top of the stack, and it can't go anywhere else. To remove you'd call a Pop, which will remove the top element of the stack. Now this seems rather limited in its uses, but they are widely used in programming. As you read this your computer is using multiple stacks just to keep itself running.
And so this article comes to a close. I hope I have't bored you to death and that you learned a little. Later I'll discuss some more data structures. Most likely they will be the Queue, Heap, and Binary Tree(probably BST).
Thursday, December 7, 2006
By John, Annie, Lucy and the Woof-Woofs at 1:35 PM
So all of my projects, papers, and assignments are finished. Now it is on to finals. I've got one on Saturday at 8am and then one on Tuesday(my birthday), one on Wednesday, and one on Thursday. Then this semester is over and I can get extremely drunk.
I'm going to do another article post next. It's going to be over some data structures that programmers use. Jon needs the information for is homework that I'm giving him. So this will give me a chance to talk about them for his sake and give you something to read.
By John, Annie, Lucy and the Woof-Woofs at 4:32 PM
So another homework assignment and a project done. Tonight I plan to get my paper done and started on the Lua project. I'm hoping that I can get the script to run and get it to accept some acceptable input strings. This is a long shot considering that my paper could take all night by itself. Three more days of "crunch time."