The Student Room Group

D1 (Decision 1) 17 May 2013 Official Thread

Scroll to see replies

Original post by posthumus
Lol thanks, it would be amazing if I got over 90 UMS :tongue: I would be sorted for an A in A level maths :smile: I got 50 UMS in January :tongue:

And no, always round down :smile: so you should go for 2


Hi, umm this iterations stuff I've never come across before, is in the textbook? & if it is can you tell me where please:colondollar: I don't understand it. :s-smilie:
Original post by otrivine
but wait in Binary if you have 2.03 you make it 3, and check the name of the person?


No we're talking about finding number of iterations here using n= log2x

And besides you wouldn't ever get 2.03, you will only get either an integer or a number with .5 on the end (where you always round up)
Original post by Fortitude
Hi, umm this iterations stuff I've never come across before, is in the textbook? & if it is can you tell me where please:colondollar: I don't understand it. :s-smilie:


It came up in January so it won't come up again :smile:

There are very few questions in the book.

Well the one that came up in January was for binary search, the other type is for bubble & quick sort.

n/2 (n-1) <<< shows you how many passes at most you would need to do :smile: where n is the number of variables.

^ So if anything were to come up about iterations it would be that one :smile:

EDIT: That formula by the way is for bubble sort & quick sort
(edited 10 years ago)
Original post by posthumus
No we're talking about finding number of iterations here using n= log2x

And besides you wouldn't ever get 2.03, you will only get either an integer or a number with .5 on the end (where you always round up)


for that iterations I use logbase 2 and what ever they give . is more faster
Original post by otrivine
for that iterations I use logbase 2 and what ever they give . is more faster


Yh that's what I'd do as well, NOW ANYWAY -__-

I couldn't do the question when it came up in January. I didn't even use the other method to keep halving it.
Original post by posthumus
It came up in January so it won't come up again :smile:

There are very few questions in the book.

Well the one that came up in January was for binary search, the other type is for bubble & quick sort.

n/2 (n-1) <<< shows you how many passes at most you would need to do :smile: where n is the number of variables.

^ So if anything were to come up about iterations it would be that one :smile:

EDIT: That formula by the way is for bubble sort & quick sort


Thank you, so just to check if there were 6 variables in a quick sort you'd need to do 15 passes at most?:colondollar:
Original post by posthumus
Yh that's what I'd do as well, NOW ANYWAY -__-

I couldn't do the question when it came up in January. I didn't even use the other method to keep halving it.


good thing you said this actually so if we logbase 2 x for example and it came to 2.03 we round to 2 or 3, is 2 right? and if we get anything above 2.5 or including 2.5 we round to 3
Original post by Fortitude
Thank you, so just to check if there were 6 variables in a quick sort you'd need to do 15 passes at most?:colondollar:


Yup ! :biggrin:

Original post by otrivine
good thing you said this actually so if we logbase 2 x for example and it came to 2.03 we round to 2 or 3, is 2 right? and if we get anything above 2.5 or including 2.5 we round to 3


No always round down. Look in January 2013 we had 26 variables, if you do logbase2(26) you get 4.7

When you use the other method:

26/2 = 13
14/2 = 7
6/2 = 3
2/2 = 1

you can clearly see it takes 4 iterations at most, but again... don't worry, it won't come up ! :tongue:
Original post by posthumus
Yup ! :biggrin:



No always round down. Look in January 2013 we had 26 variables, if you do logbase2(26) you get 4.7

When you use the other method:

26/2 = 13
14/2 = 7
6/2 = 3
2/2 = 1

you can clearly see it takes 4 iterations at most, but again... don't worry, it won't come up ! :tongue:



However, on question 3)b) on page 78 it comes to 9.96 and they round to 10
Original post by posthumus
It came up in January so it won't come up again :smile:

There are very few questions in the book.

Well the one that came up in January was for binary search, the other type is for bubble & quick sort.

n/2 (n-1) <<< shows you how many passes at most you would need to do :smile: where n is the number of variables.

^ So if anything were to come up about iterations it would be that one :smile:

EDIT: That formula by the way is for bubble sort & quick sort

So lets say you had 8 integers that you had to apply bubble sort to. What would I input into the formula?
Reply 530
Original post by posthumus
Lol thanks, it would be amazing if I got over 90 UMS :tongue: I would be sorted for an A in A level maths :smile: I got 50 UMS in January :tongue:

And no, always round down :smile: so you should go for 2


Wasn't it 5 iterations in Jan 2013 though?

Log26/log2 =4.7

??

Or did you mean rounding down if it's below .5 ( like 2.03) ?
Original post by otrivine
However, on question 3)b) on page 78 it comes to 9.96 and they round to 10


But apparently the answer to Jan 2013 was 4 :s-smilie: according to Arsey anyway. Either Arsey is wrong in his mark scheme or the book is wrong. But don't worry about it honestly ! It came up in January lol :tongue:


Original post by Dilzo999
So lets say you had 8 integers that you had to apply bubble sort to. What would I input into the formula?


8/2 (8-1)

4 x 7 = 28

:smile:
Guys do you think flowcharts will come up again this exam? It's my only enemy in D1 :biggrin:.
Original post by Dilzo999
So lets say you had 8 integers that you had to apply bubble sort to. What would I input into the formula?


The ans would be 28 because 8/2 = 4 & 4x7(n-1) = 28 :smile:
Original post by posthumus
But apparently the answer to Jan 2013 was 4 :s-smilie: according to Arsey anyway. Either Arsey is wrong in his mark scheme or the book is wrong. But don't worry about it honestly ! It came up in January lol :tongue:




8/2 (8-1)

4 x 7 = 28

:smile:



OH godness, to be honest I dont want to take any risk with D1 cause if you lose 2 marks that may cost you a grade
Reply 535
Original post by posthumus
But apparently the answer to Jan 2013 was 4 :s-smilie: according to Arsey anyway. Either Arsey is wrong in his mark scheme or the book is wrong. But don't worry about it honestly ! It came up in January lol :tongue:




8/2 (8-1)

4 x 7 = 28

:smile:



It's 5 iterations in Mark scheme
Original post by Vaner
Wasn't it 5 iterations in Jan 2013 though?

Log26/log2 =4.7

??

Or did you mean rounding down if it's below .5 ( like 2.03) ?


I'm really not sure :confused: Arsey said it was 4 iterations... and used the common method. It makes sense that it was 4.

however when logging 26 with the base 2 you get 4.7
I think the halving method is more solid and more understandable when you're in that situation.33
Original post by Vaner
It's 5 iterations in Mark scheme


Where did you get 5 from, I am using Arsey's Mark Scheme ?

To be fair I first did this:

26/2 = 13
13/2 = [6.5] = 7
7/2 = [3.5] = 4
4/2 = 2
2/1 = 1

Which is 5 iterations, so I think Arsey could be wrong :tongue:
Reply 539
Original post by posthumus
I'm really not sure :confused: Arsey said it was 4 iterations... and used the common method. It makes sense that it was 4.

however when logging 26 with the base 2 you get 4.7


that was a strange question, no it is 5 iterations, I didn't include the final location as an iteration stupidly.

Also on the CPA question I put my 5.5 line on day 6 :rolleyes: so B can actually escape.

Quick Reply

Latest

Trending

Trending