CSC148 SLOG
Thursday, April 3, 2014
Week 12 - Exam Review
Like last week, there wasn't any immediate new information being taught. Again, we just went through some standard "big o" and tracing problems. One really cool thing I found interesting was being able to modify the recursion limit of a function using "sys" and the "getrecrusionlimit()" method. We also went through some new methods to solve the Fibonacci number function, but I guess that went over everyone's head because of exams coming up. Other than that, the week was pretty much just basic review.
Week 11 - Test Review
This week didn't have any new material. We basically had a review session for the test coming up. Regarding the test, I believe that it could have gotten a better mark, but regarding the circumstances, it could have gotten worse. The basic concepts for review were basically recursive functions involving trees. It can get pretty tricky when dealing with classes and methods, but I guess practice makes perfect.
Monday, March 24, 2014
Week 10 - Sorting
Last semester, we earned about different types of sorting techniques, but we never actually understood how Python executed these internally. However, understanding different algorithms such as the Quicksort and the Merge Sort will give us a broader understanding of how these algorithms work. An interesting way on how the Quicksort method works is that it requires a helper function in order to partition the input given. The overall algorithm also sorts the input recursively allowing the efficiency of the code to take log(n) steps in most cases.
Week 9 - Complexity
This week had an emphasis on understanding and writing efficient code. The week consisted of writing and comparing different types of algorithms that achieved the same goal, but either had a harder or easier time doing it. Looking at the efficiency of these algorithms mathematically involved us looking at something called a "step". A "step" is something the program can do in a fixed amount of time. The amount of "steps" the program takes is directly related to the length of the input given. Like last semester, looking at the algorithm and determining whether it is a linear, quadratic, cubic, ect. is important to understand the efficiency of the algorithm.
Saturday, March 8, 2014
Week 8 - Binary Search Trees
This week was more of a extension of what we learned on trees. The difference here is that BST's are trees with conditions. Discussed in class, these conditions are used so that we can efficiently search through information quickly.
Some of these methods that include finding a particular element in the BST involve some recursion.
Overall, it was a pretty interesting topic to learn, and it looks like its gonna be very important concept to understand in the coming years.
Some of these methods that include finding a particular element in the BST involve some recursion.
Overall, it was a pretty interesting topic to learn, and it looks like its gonna be very important concept to understand in the coming years.
Wednesday, February 26, 2014
Week 7 - Linked Lists
So after a much needed "break" from school, this week we learned about Linked Lists. These are essentially Trees with a branching factor of 1. The reason for this datatype is so that we may decrease the amount of time an operation takes in a function given its parameter. In our labs, we're just getting familiar with linked lists so that in the future, we can see how linked lists can be used a lot more efficiently compared to nested lists. Dan showed that the linear growth of a list takes a long time to operate on, and that linked lists are used to speed that up.
Friday, February 14, 2014
Week 6 - Trees
This week, we learned about a new type of data structure called Trees. This method of organizing data is used when the data you have is not in a linear structure (For example: Stacks, Lists, Queues, ect.).
With Trees, its not always obvious to organize things in a linear manner, instead, the idea of hierarchy is used to organize the data.
The basis of a tree structure consists of Nodes and Edges. Nodes can be thought of as a "point" in a tree (like the seed, or leaves), while Edges "connect" these Nodes together (much like branches). The main methods used for a Tree structure are traversing through, inserting/removing nodes, and inserting/removing subtrees at a Node.
Overall, the terminology and the overall concept of tree's aren't that hard to understand. Hopefully understanding the code will be just as easy.
With Trees, its not always obvious to organize things in a linear manner, instead, the idea of hierarchy is used to organize the data.
The basis of a tree structure consists of Nodes and Edges. Nodes can be thought of as a "point" in a tree (like the seed, or leaves), while Edges "connect" these Nodes together (much like branches). The main methods used for a Tree structure are traversing through, inserting/removing nodes, and inserting/removing subtrees at a Node.
Overall, the terminology and the overall concept of tree's aren't that hard to understand. Hopefully understanding the code will be just as easy.
Subscribe to:
Comments (Atom)