The Student Room Group

D1: Do I repeat the last stage in a bubble sort/quick sort?

From what I have done for edexcel d1:

It has always been:

Bubble sort = Do not repeat when finished. Say sort complete.

Quick sort = Repeat when finished so every value is a confirmed pivot/in a square.

thnx

Scroll to see replies

Original post by Mihael_Keehl
From what I have done for edexcel d1:

It has always been:

Bubble sort = Do not repeat when finished. Say sort complete.

Quick sort = Repeat when finished so every value is a confirmed pivot/in a square.

thnx


This is what my teacher has told me also
Actually scrap what I said. In a bubble sort, you in a way repeat at the end to show that there are no swaps. This is seen in the textbook.

Quicksort is as you said repeated
Original post by Student403
This is what my teacher has told me also


Original post by Student403
Actually scrap what I said. In a bubble sort, you in a way repeat at the end to show that there are no swaps. This is seen in the textbook.

Quicksort is as you said repeated


I saw this in the cgp guide however in past edexcel questions, btw they have seldom ever used bubble sort they dont repeat the stage if I may link you.

https://drive.google.com/folderview?id=0B23NLD5L6099fi03eUFoOG1pUWdqalhQX3dDQU9KclRtX01vbGdGaFBlWGVsTkcwVkNaQlU&usp=sharing&tid=0B23NLD5L6099fmRyZWJXa0tmT3RhNW4ybU9TWjNhMkhQVGxMcHp4Zk5ISjN1VGxGdzZXbFE

https://drive.google.com/folderview?id=0B23NLD5L6099flRFV0xxX3h6LVcwY0pDRFh4MFBXaGc0TWpQWktjaUFNZzZ1SVZDVnA5Szg&usp=sharing&tid=0B23NLD5L6099fmpzaHRFZFBQZm01VVR5VGJhN3N4OF9zLWd1d2RUcTZ2WXY1RnhiR3VLczA

I can't link selectively but it is in the 6889 stuff

And here I think what I will do in summer is:

Quick sort: Everything confirmed pivoted/ in squares then after say "Sort Complete" List pivots alongside working out

Bubble sort: Just say sort complete but state that at the end of each line it is the end of the nth pass.

Is that better :P

Interesting d1 summer 2k15 first year they asked all 3 algorithms and displaced the bin packing :biggrin:
Original post by Mihael_Keehl
I saw this in the cgp guide however in past edexcel questions, btw they have seldom ever used bubble sort they dont repeat the stage if I may link you.

https://drive.google.com/folderview?id=0B23NLD5L6099fi03eUFoOG1pUWdqalhQX3dDQU9KclRtX01vbGdGaFBlWGVsTkcwVkNaQlU&usp=sharing&tid=0B23NLD5L6099fmRyZWJXa0tmT3RhNW4ybU9TWjNhMkhQVGxMcHp4Zk5ISjN1VGxGdzZXbFE

https://drive.google.com/folderview?id=0B23NLD5L6099flRFV0xxX3h6LVcwY0pDRFh4MFBXaGc0TWpQWktjaUFNZzZ1SVZDVnA5Szg&usp=sharing&tid=0B23NLD5L6099fmpzaHRFZFBQZm01VVR5VGJhN3N4OF9zLWd1d2RUcTZ2WXY1RnhiR3VLczA

I can't link selectively but it is in the 6889 stuff

And here I think what I will do in summer is:

Quick sort: Everything confirmed pivoted/ in squares then after say "Sort Complete" List pivots alongside working out

Bubble sort: Just say sort complete but state that at the end of each line it is the end of the nth pass.

Is that better :P

Interesting d1 summer 2k15 first year they asked all 3 algorithms and displaced the bin packing :biggrin:

Hmm I see what you mean but I feel like I just need to play it safe by listing both at the end. I guess we'll see in mark schemes yep. We'll learn it by summer, no doubt
Reply 5
Original post by Mihael_Keehl
From what I have done for edexcel d1:

It has always been:

Bubble sort = Do not repeat when finished. Say sort complete.

Quick sort = Repeat when finished so every value is a confirmed pivot/in a square.

thnx


Btw With quick sort you don't have to repeat the last stage you can say
"All items are fixed or in a sub list of one, therefore the list is in order"
You don't have to fix all the items as long as they have two fixed items either side
Off topic but which dumbf*** thought of the name quicksort for these marathon-type questions
Do you guys make a key when doing these question types for quick sort; i.e. square = fixed pivot etc.
Original post by Student403
Hmm I see what you mean but I feel like I just need to play it safe by listing both at the end. I guess we'll see in mark schemes yep. We'll learn it by summer, no doubt


sry idk what you mean. By repeating do you mean do the final pass again?

Original post by RonnieRJ
Btw With quick sort you don't have to repeat the last stage you can say
"All items are fixed or in a sub list of one, therefore the list is in order"
You don't have to fix all the items as long as they have two fixed items either side

I see your logic, aren't your sentences superflous though, afaik they say List complete as B1/A1.

Original post by Student403
Off topic but which dumbf*** thought of the name quicksort for these marathon-type questions


idd :P

have you seen the edexcel question 5 on the quick sort/bubble sort lmaooo
Original post by Mihael_Keehl
Do you guys make a key when doing these question types for quick sort; i.e. square = fixed pivot etc.


sry idk what you mean. By repeating do you mean do the final pass again?


I see your logic, aren't your sentences superflous though, afaik they say List complete as B1/A1.



idd :P

have you seen the edexcel question 5 on the quick sort/bubble sort lmaooo

Yea that's what I meant. I haven't done any past papers tho this is just going off what my teacher said so better to follow the markscheme whatever that says

Nah I haven't
Reply 9
Original post by Mihael_Keehl
Do you guys make a key when doing these question types for quick sort; i.e. square = fixed pivot etc.


sry idk what you mean. By repeating do you mean do the final pass again?


I see your logic, aren't your sentences superflous though, afaik they say List complete as B1/A1.



idd :P

have you seen the edexcel question 5 on the quick sort/bubble sort lmaooo


It's just how I was taught and it might save time ie it takes me less time to write a little sentence than write out the whole list and underline all the items (underlined -> fixed) and still have to write list complete
But obv up to you how you do it thought I'd pop that in
Original post by Student403
Yea that's what I meant. I haven't done any past papers tho this is just going off what my teacher said so better to follow the markscheme whatever that says

Nah I haven't


Ok thnx :smile:

Original post by RonnieRJ
It's just how I was taught and it might save time ie it takes me less time to write a little sentence than write out the whole list and underline all the items (underlined -> fixed) and still have to write list complete
But obv up to you how you do it thought I'd pop that in


ohhh didn't realise you meant an alternative, thanks I see what are you saying in that regard.
Original post by Student403
Yea that's what I meant. I haven't done any past papers tho this is just going off what my teacher said so better to follow the markscheme whatever that says

Nah I haven't


is there a d1 thread btw :teehee:
Original post by Mihael_Keehl
is there a d1 thread btw :teehee:


How far through the sylalbus are you guys.

I have done all of the content. Chapter 1 and Chapter 7 are very simple tbh.

Just the djisktra stuff is awk as well as the definitions.

Original post by RonnieRJ
Btw With quick sort you don't have to repeat the last stage you can say
"All items are fixed or in a sub list of one, therefore the list is in order"
You don't have to fix all the items as long as they have two fixed items either side


Original post by Student403


all those mathmos do is C1 and c2 while I do D1 :u:
Original post by Mihael_Keehl
How far through the sylalbus are you guys.

I have done all of the content. Chapter 1 and Chapter 7 are very simple tbh.

Just the djisktra stuff is awk as well as the definitions.





all those mathmos do is C1 and c2 while I do D1 :u:


I covered it in a couple of weeks last year. To be honest I don't think it makes a difference if you rush through it all. You have to relearn it anyway before the exam
Original post by Student403
I covered it in a couple of weeks last year. To be honest I don't think it makes a difference if you rush through it all. You have to relearn it anyway before the exam


nice, idd :P
Original post by Mihael_Keehl
How far through the sylalbus are you guys.

I have done all of the content. Chapter 1 and Chapter 7 are very simple tbh.

Just the djisktra stuff is awk as well as the definitions.





all those mathmos do is C1 and c2 while I do D1 :u:


I've finished it and going through M1-M2 currently :smile:
Original post by RonnieRJ
I've finished it and going through M1-M2 currently :smile:


nice :smile:
Original post by RonnieRJ
I've finished it and going through M1-M2 currently :smile:


Are you doing fm a2?
Original post by Mihael_Keehl
Are you doing fm a2?


Nope I just picked up the AS further maths like last minute lol :smile:

Quick Reply

Latest