Here is a post from a programming blog I am required to keep up. I thought some of my readers might find it funny. I am discussing a rather difficult recent assignment. The Grrz method is supposed to be a great way to expand mental capability. I think its a way for the teacher to be lazy.
Sooooooo..... Four hours later I think I finally know what the Grrz method is. I think it is better put in comparison to the sink or swim method.
Take someone who cant swim. Put them in a helicopter, fly them out over the Marinas Trench, make sure there is no other form of rescue besides the helicopter, and push them in. Perhaps wieghts or restraints would be appropriate as well.Then from the air tell them to swim back to the helicopter.
That seems to be the Grrz method. At least with this latest assignment.
We are supposed to use the RandomAccessFile class to find an answer in little time... with no help other then the suggestion to search for dbf header format...
Well RAF can read and write. No document I could find could tell me exactly how this reading took place, only that it does. So I have no idea how it will parse...
Finally I figure out how to read the document in and make sure it splits correctly, readFully(byte[] b) but am still lost at the offsets so I hacked it...
Not really the coolest code to display... I hope we figure out a better solution soon!
On the bright side all the dbf files open and appear correct! So that is exciting. More on this as it develops.
Score 16 out of 100 (if the code reference counts :)
Thursday, September 17, 2009
Sunday, September 13, 2009
Updated sometime this millenia...
WOW way too long since I have been here... I don't even have an excuse prepared this time... DARN!
Oh well I bet no one will even notice. :)
UPDATE: I am now at college again! After an excruciatingly long six months of waiting I have made it back to my beloved campus at BYUI. I am moved in and started the first week of school which had surprisingly little homework... must be preparing me for the death load soon to follow.
I am making the critical error of taking to many major classes. I have 4 200 level classes, one 300 level and one 400 level class. I might die. wish me luck.
On a bright note I am taking an art class and I am pretty excited about it. I need the supplies I ordered to show up soon though. Or else I will have nothing to draw on. Maybe I should stop being a cheapskate and just get the art kit the university supplies. NAH.
Well got to run, but more is on the way. So stay tuned.
Oh well I bet no one will even notice. :)
UPDATE: I am now at college again! After an excruciatingly long six months of waiting I have made it back to my beloved campus at BYUI. I am moved in and started the first week of school which had surprisingly little homework... must be preparing me for the death load soon to follow.
I am making the critical error of taking to many major classes. I have 4 200 level classes, one 300 level and one 400 level class. I might die. wish me luck.
On a bright note I am taking an art class and I am pretty excited about it. I need the supplies I ordered to show up soon though. Or else I will have nothing to draw on. Maybe I should stop being a cheapskate and just get the art kit the university supplies. NAH.
Well got to run, but more is on the way. So stay tuned.
Sunday, May 31, 2009
Stigmas proved true...
I love role-playing or rping whichever you prefer. The title of GameMaster comes from role-playing games where one of the players is the referee so to speak and and plays the part of the monsters and non-player characters the other players come across. It is a fun exercise of imagination and a great way to hang out as typically more talking than playing seems to get done in an average session. It is a great activity and yet it seems more stigmas are attached to people who play role-playing games than most activities I know about. Just because there are a few weird people involved in rping doesn't mean we all are psychos. Just because OJ Simpson was a football player doesn't mean all football players are murderous creeps.
One such terrible stigma is that all role players live in their mother's basement. Seriously how many gamers live in thier parent's basement... besides me... haha.
So its true. How Terrible. I could go through all my lame excuses like being a junior in college and still in college, or that I am poor in this terrible economy, but it would all be useless. How lame I am.
Hey it could be worse? I could be as oblivious as these gamers in this true following story...
(Side Note Ed is the Gamemaster and Eric is one of the characters)
ED: You see a well groomed garden. In the middle, on a small hill, you see a gazebo.
ERIC: A gazebo? What color is it?
ED: (Pause) It's white, Eric.
ERIC: How far away is it?
ED: About fifty yards.
ERIC: How big is it?
ED: (Pause) It's about thirty feet across, fifteen feet high, with a pointed top.
ERIC: I use my sword to detect good on it.
ED: It's not good, Eric. It's a gazebo!
ERIC: (Pause) I call out to it.
ED: It won't answer. It's a gazebo!
ERIC: (Pause) I sheathe my sword and draw my bow and arrows. Does it respond in any way?
ED: No, Eric, it's a gazebo!
ERIC: I shoot it with my bow (roll to hit). What happened?
ED: There is now a gazebo with an arrow sticking out of it.
ERIC: (Pause) Wasn't it wounded?
ED: Of course not, Eric! It's a gazebo!
ERIC: (Whimper) But that was a plus three arrow!
ED: It's a gazebo, Eric, a gazebo! If you really want to try to destroy it, you could try to chop it with an axe, I suppose, or you could try to burn it, but I don't know why anybody would even try. It's a *)@#! gazebo!
ERIC: (Long pause. He has no axe or fire spells.) I run away.
ED: (Thoroughly frustrated) It's too late. You've woken up the gazebo, and it catches you and eats you.
ERIC: (Reaching for his dice) Maybe I'll roll up a fire-using mage so I can avenge my Paladin.
At this point, the increasingly amused fellow party members restored a modicum of order by explaining what a gazebo is. It is solely an afterthought, of course, but Eric is doubly lucky that the gazebo was not situated on a grassy gnoll...
So in closing I think I am doing a lot better than some people and that makes it alright... I think. I know elves and dwarfs are not real, and I cannot conjure any spells no matter how hard I try, so I have a good head on my shoulders despite what all the naysayers would have you believe. Well before I go... could anyone tell me what a gazebo is?
One such terrible stigma is that all role players live in their mother's basement. Seriously how many gamers live in thier parent's basement... besides me... haha.
So its true. How Terrible. I could go through all my lame excuses like being a junior in college and still in college, or that I am poor in this terrible economy, but it would all be useless. How lame I am.
Hey it could be worse? I could be as oblivious as these gamers in this true following story...
(Side Note Ed is the Gamemaster and Eric is one of the characters)
ED: You see a well groomed garden. In the middle, on a small hill, you see a gazebo.
ERIC: A gazebo? What color is it?
ED: (Pause) It's white, Eric.
ERIC: How far away is it?
ED: About fifty yards.
ERIC: How big is it?
ED: (Pause) It's about thirty feet across, fifteen feet high, with a pointed top.
ERIC: I use my sword to detect good on it.
ED: It's not good, Eric. It's a gazebo!
ERIC: (Pause) I call out to it.
ED: It won't answer. It's a gazebo!
ERIC: (Pause) I sheathe my sword and draw my bow and arrows. Does it respond in any way?
ED: No, Eric, it's a gazebo!
ERIC: I shoot it with my bow (roll to hit). What happened?
ED: There is now a gazebo with an arrow sticking out of it.
ERIC: (Pause) Wasn't it wounded?
ED: Of course not, Eric! It's a gazebo!
ERIC: (Whimper) But that was a plus three arrow!
ED: It's a gazebo, Eric, a gazebo! If you really want to try to destroy it, you could try to chop it with an axe, I suppose, or you could try to burn it, but I don't know why anybody would even try. It's a *)@#! gazebo!
ERIC: (Long pause. He has no axe or fire spells.) I run away.
ED: (Thoroughly frustrated) It's too late. You've woken up the gazebo, and it catches you and eats you.
ERIC: (Reaching for his dice) Maybe I'll roll up a fire-using mage so I can avenge my Paladin.
At this point, the increasingly amused fellow party members restored a modicum of order by explaining what a gazebo is. It is solely an afterthought, of course, but Eric is doubly lucky that the gazebo was not situated on a grassy gnoll...
So in closing I think I am doing a lot better than some people and that makes it alright... I think. I know elves and dwarfs are not real, and I cannot conjure any spells no matter how hard I try, so I have a good head on my shoulders despite what all the naysayers would have you believe. Well before I go... could anyone tell me what a gazebo is?
Tuesday, April 28, 2009
Portal
I have been trying a new game, and just recently finished it. It is called Portal. Created by Valve the makers of Half-life, I think it is the only activity that can make you enjoy being nauseated, and even make you try to become more so... because its cooool. Also for a puzzle game it has a great storyline.
As it starts out you are a test subject (volunteer perhaps? it never makes that clear) at the Aperature Science Enrichment Center which is supposedly helping enrich your mind and help you become a better problem solver, but it seems obvious your real purpose is to test the cool portal gun they invented. After a couple tutorial segments you have the portal gun which shoots out a blue and an orange portal. If you walk through one portal you come out the other. So does any other object. So you play through a series of fun puzzles which have rather awesome solutions involving these portals. They can also be severely disorienting. :)
However the computer guiding you through the challenges is acting rather strange. Sometimes it even sounds sarcastic and sinister. Suddenly on one level she informs you the challenge you were supposed to do is under maintenance and you will be placed in a military android testing area instead. Sorry for any inconvenience. The Challenges become increasingly... real, even with the Computer's assurances that everything is perfectly safe and following testing protocols. Then you find a broken section of the testing area inside which are scribbled messages calling for help the floor littered with empty emergency rations, and marks representing a long length of time. Something is wrong. I don't want to spoil the ending for those who want to play the game but I will leave one last clue. The Cake is a lie.
The music and graphics were excellent at creating mood, one thing Valve excels at. The gameplay was also original and very fun. In fact sometimes I would just play around and not complete the levels because goofing with the portal gun is super entertaining. Probably the only thing I didn't like was the length. It was really short in its storyline mode. It does include many bonus levels as well, but I would have liked to have the storyline be a little longer than 2 hours on my first try. I will give the game a 9 out of 10 Excellent job Valve. If you want the game I suggest buying the Orange Box set by valve, it is one of the best values for PC games including some of the best titles ever made for the PC for $30.
As another sample here is the trailer for the game it captures a good part of the gameplay. Enjoy!
As it starts out you are a test subject (volunteer perhaps? it never makes that clear) at the Aperature Science Enrichment Center which is supposedly helping enrich your mind and help you become a better problem solver, but it seems obvious your real purpose is to test the cool portal gun they invented. After a couple tutorial segments you have the portal gun which shoots out a blue and an orange portal. If you walk through one portal you come out the other. So does any other object. So you play through a series of fun puzzles which have rather awesome solutions involving these portals. They can also be severely disorienting. :)
However the computer guiding you through the challenges is acting rather strange. Sometimes it even sounds sarcastic and sinister. Suddenly on one level she informs you the challenge you were supposed to do is under maintenance and you will be placed in a military android testing area instead. Sorry for any inconvenience. The Challenges become increasingly... real, even with the Computer's assurances that everything is perfectly safe and following testing protocols. Then you find a broken section of the testing area inside which are scribbled messages calling for help the floor littered with empty emergency rations, and marks representing a long length of time. Something is wrong. I don't want to spoil the ending for those who want to play the game but I will leave one last clue. The Cake is a lie.
The music and graphics were excellent at creating mood, one thing Valve excels at. The gameplay was also original and very fun. In fact sometimes I would just play around and not complete the levels because goofing with the portal gun is super entertaining. Probably the only thing I didn't like was the length. It was really short in its storyline mode. It does include many bonus levels as well, but I would have liked to have the storyline be a little longer than 2 hours on my first try. I will give the game a 9 out of 10 Excellent job Valve. If you want the game I suggest buying the Orange Box set by valve, it is one of the best values for PC games including some of the best titles ever made for the PC for $30.
As another sample here is the trailer for the game it captures a good part of the gameplay. Enjoy!
Monday, April 27, 2009
First Snow of... Spring?
Its days like these that make people move to Florida...
Yesterday the 26th of APRIL it snowed. Heavy too. We received almost a foot of snow in several hours. I had to dig my car out to use it, and almost had to shovel the driveway! I walked into church in the morning and in the 20 ft walk to the door I was coated in snow and looked like Frosty the snowman really had come back.
Then suddenly as it had come it departed. I came home in the snow, took a nap and when I woke up it was green again. It caught me by surprise both times. In the morning it took my brain quite a while to figure out what was wrong about the snow outside. I kept thinking snow is normal... but for some reason I don't think it should be here... OH! WHAT THE...! After it was gone same story. I looked outside and a little snow remained here and there and looked like soggy toilet paper. I was trying to figure out who would TP our house, then suddenly recalled it had snowed that morning. (I was having some real problems waking up that day :)
Idaho really has some odd weather patterns. I wish snow in April, May, or June was a super rare exception, but it happens more often than we would expect. It usually leads to a late frost which really frustrates farmers. So much for Global Warming.
Yesterday the 26th of APRIL it snowed. Heavy too. We received almost a foot of snow in several hours. I had to dig my car out to use it, and almost had to shovel the driveway! I walked into church in the morning and in the 20 ft walk to the door I was coated in snow and looked like Frosty the snowman really had come back.
Then suddenly as it had come it departed. I came home in the snow, took a nap and when I woke up it was green again. It caught me by surprise both times. In the morning it took my brain quite a while to figure out what was wrong about the snow outside. I kept thinking snow is normal... but for some reason I don't think it should be here... OH! WHAT THE...! After it was gone same story. I looked outside and a little snow remained here and there and looked like soggy toilet paper. I was trying to figure out who would TP our house, then suddenly recalled it had snowed that morning. (I was having some real problems waking up that day :)
Idaho really has some odd weather patterns. I wish snow in April, May, or June was a super rare exception, but it happens more often than we would expect. It usually leads to a late frost which really frustrates farmers. So much for Global Warming.
Subscribe to:
Posts (Atom)