36:27,on the growth order of the "selection and sort" algo: It's in quadratic order but more efficient than a purely quadratic algo. The total number of primitive steps is the sum of : n+(n-1)+(n-2)+...+1, a result of the decreasing suffix of the list, hence it's the sum of the arithmetic/Gauss series which is (n/2)(n+1), or (n^2)/2+n/2.
@DavidMadsen:'start+ 4k' is a constant given an index k. That is, for a list that consists of say only integers, you would skip a multiple of 4 memory cells to access any element (Integer has 4 bits). However, for a heterogeneous list (integers, characters etc.), the elements may be stored in varying number of bits, so you can no longer skip in multiples of 4, but of variable numbers (say x). This would be a linear relationship, depending on x.
@DavidMadsen I'm assuming you're talking about 13:55. Think about it carefully. k is just a number (in this case, an index). If you do start + 4*k, it's the same if k is 0, 1, 50000... you still do start + 4*k only one time in order to find the element you're looking for. Later on in the video, he shows a linked list which would be linear time because to find the kth element, you must advance through the links k times.
Arrays are basically set of elements of same name and same datatype . The array lists are the elements that are present in the array in the form of lists
theres less tan 20 students there and some of them are on the back meaning they dont care about it yet this video has more than 50 thousand views, how is that possible when there are only 7000 people in the world?
Ive just been jumping around the vid. Are you referring to linked list @ 17:40? If so yes. There is a linked list class called LinkedList..Its in java.util if that helps
yea I'm a little afraid of ps5, even as a semi experienced programmer of multiple languages haha that order stuff is seriously difficult to grasp, took me 2 days to get through the lecture to my liking. I'm committed to completing the course though!
(Talk soft then loud) -> Iterate this. If talk at constant volume, the class will sleep. Same way highways need curves, if they are always straight then you fall asleep.
Technically PS5 isn't due till the next video, based on their calendar. I haven't started it yet either. i think it was more that lecture 8 is really the first conceptually hard part to understand.
Thanks you Professor Grimson and Guttag for such nice lecturers.
36:27,on the growth order of the "selection and sort" algo: It's in quadratic order but more efficient than a purely quadratic algo. The total number of primitive steps is the sum of : n+(n-1)+(n-2)+...+1, a result of the decreasing suffix of the list, hence it's the sum of the arithmetic/Gauss series which is (n/2)(n+1), or (n^2)/2+n/2.
n! for selection sort
I watched this my junior year of high school 16 years ago and it confirmed to me that i wanted to study computer science.
I feel like this course has helped me improve my jezzball score ... the midpoint method works great 👍
love these lectures!!!
@DavidMadsen:'start+ 4k' is a constant given an index k. That is, for a list that consists of say only integers, you would skip a multiple of 4 memory cells to access any element (Integer has 4 bits). However, for a heterogeneous list (integers, characters etc.), the elements may be stored in varying number of bits, so you can no longer skip in multiples of 4, but of variable numbers (say x). This would be a linear relationship, depending on x.
@DavidMadsen I'm assuming you're talking about 13:55.
Think about it carefully. k is just a number (in this case, an index). If you do start + 4*k, it's the same if k is 0, 1, 50000... you still do start + 4*k only one time in order to find the element you're looking for.
Later on in the video, he shows a linked list which would be linear time because to find the kth element, you must advance through the links k times.
Arrays are basically set of elements of same name and same datatype .
The array lists are the elements that are present in the array in the form of lists
Why do we need that j in bubble sort
j is the number of times the loop is executed while i is the number of elements that are bubble sorted
@Yazk17 yes. instead of having pointers, you could hold the next object in the current object.
10:30
thank you
theres less tan 20 students there and some of them are on the back meaning they dont care about it yet this video has more than 50 thousand views, how is that possible when there are only 7000 people in the world?
A comment from the future?
👍👍👍👍👍👍👍👍
Does this guy ever put the right glasses on?
thanks a lot.
Ive just been jumping around the vid. Are you referring to linked list @ 17:40? If so yes. There is a linked list class called LinkedList..Its in java.util if that helps
I don't think we need to update the variable j in for j loop of selSort, that is, we can delete j = j + 1 in for j loop. Anyone agree?
How is "start + 4*k" constant?
Wasn't k linear, i.e. double k and you will essentially double the time to find it?
yea I'm a little afraid of ps5, even as a semi experienced programmer of multiple languages haha that order stuff is seriously difficult to grasp, took me 2 days to get through the lecture to my liking. I'm committed to completing the course though!
What's the difference between array and list?
Its a technique to keep your attention. If his audibility stays the same, you could sleep before you realize.
(Talk soft then loud) -> Iterate this. If talk at constant volume, the class will sleep. Same way highways need curves, if they are always straight then you fall asleep.
I don't think the concept of pointers is really explained in the lectures. I get it because I know C beforehand.
the camera doesn't show the code for selection sort :(
Does anyone have it / know how to actually write it?
Technically PS5 isn't due till the next video, based on their calendar. I haven't started it yet either. i think it was more that lecture 8 is really the first conceptually hard part to understand.
Woo changed my mind, I like ps5! Not nearly as tough as I thought so far, I'm done the first 2 problems at least, without much difficulty.
predicted ps5 a decade ago
@@sunritroykarmakar4406 I see you
@recursion27 love your name . how appropriate
Binary surch always halt.... Zeno's paradox isn't real for discrete elements.
Mr. Eric Grimson, I would love to be your student
he's a sugar crazed zombie! thank God 'apple, throwing out candy, foo and bar, python'
Мv8
I gotta get rid of this candy.
I get all the lectures but I cant do the programming lol
What's the difference between array and list?