Today we began searching for input. This relates a bit to sorting in that rather than sorting, you look for a item in a given table. It does not quite make much sense to me, because when we started off, we used bubble sort, which was quite elementary and not quite useful. Then we used shell, exchange and what not and it worked quite a bit better. However, then an issue came up. It was ridiculously simple. Even just looking at it, I could tell that it was a retarded method to do it. So I came up with a theory of using a weird kind of sort. Then the next kind of search was introduced.
Ironically enough (wouldn't it be ironic if we were all made of iron?) it was similar to what I was thinking of doing, just a little bit less efficient. The method I was thinking of was first getting right into the middle of the table, and calculate the measure of difference. (From a list of a-z, looking for a b) I would first give all letters a score, (x-y) and search= (x+y)/2. Depending on search, you would look higher or lower depending on how far it is from your average, and geometrically sort (I think that's the word). The method we were taught was somewhat similar and somewhat different.
We were taught to get a table. IE
1 a
2 b
3 c
4 d
5 e
6 f
7 g
8 h
9 i
Given the table, go to the middle. e. Then if one was looking for b, you would raise your minimum to just above your mid point, and take the middle of that again, And repeat until you find it or determine that said item that does not exist. Different from mine, but what I was thinking of was for a more large scale application that the scope of this course. (My video may use it though, so watch out!)
In other news, gyming today hopefully. Just starting to get into it again, slowly feeling my left
hand come back from its brutal state earlier (having fractured it, I lost pretty much all musclemass in left hand). Getting it back in shape is painful when one can curl 20 pounds like a joke with your right hand, and about 17.5 with left struggling. Ah well, it will all be better soon hopefully. Only problem is I feel like I have M arms (I think you can figure that out). Quite painful. Also going to have to start training for soccer again. At last weeks practice although I didn't really have to stop, I could really feel my body being out of shape. Plus having no muscle means I am constantly cold. So off I go to save the daaaaaaaaaay. Or not. Later my peoples.
No comments:
Post a Comment