The Student Room Logo

OCR GCSE Computer Science Paper 1 (J277/01) - 19th May 2023 [Exam Chat]

Scroll to see replies

Original post by Blazing_Legend
Bro that cs paper was sickkk 🤩 I don’t know what you guys are talking about

PS - if so thanks for lowering grade boundaries.

Aced that test 💪


ur welcome !
Original post by Blazing_Legend
There were 3, Schrödinger, which one?

Well all 3 von Neumann
Original post by Guest2091
Well all 3 von Neumann


Don't have time for all three, Babbage + don't even remember the exact questions.

PS - You didnt know who Babbage was
Original post by Blazing_Legend
Don't have time for all three, Babbage + don't even remember the exact questions.

PS - You didnt know who Babbage was


Sorry J.Prius I assumed you knew the questions as it was so easy.
PS- you didn’t know who J.Prius was
well i remember them
- you had to make a procedure to assign data to a file
- the random generator game
- and the last one on arrays and adding up the seconds the sensor was on each date
Original post by Guest2091
Sorry J.Prius I assumed you knew the questions as it was so easy.
PS- you didn’t know who J.Prius was
well i remember them
- you had to make a procedure to assign data to a file
- the random generator game
- and the last one on arrays and adding up the seconds the sensor was on each date

1. Who the hell is J Prius?

2. The file one was just creating a procedure with parameters including (data and filename)
and then you open the file add the "data" and close the file. Just to be sure, I also asked for an input for the data along with the filename and then called the procedure.

3. Oh random generator, so I used a flow chart which made it so much nicer and easier!!!! Randomly generate two numbers - ask the user for an answer - check if the user_answer is correct to num1 + num2 - if it is then add 1 to score, if not score = score and also tries = tries +1 , when tries = 3, break and exit the loop, at the end display the score.

4. This one, I must admit was difficult at first, so I think I used asked the user for the date and then I used a forloop to check if the date matched a date in the 2D array, for that i did something like arrayevents[x, 0] - I think and to find the corresponding seconds something like [x, 3] and then just added that to the local variable (seconds) I had already created. Then, at the end of the count-controlled loop, I just printed the statement as shown.

There you go, gee I cant think of a famous dude uhm......................Brian Cox, yeah that should do for now.

You're welcome.
Original post by Blazing_Legend
1. Who the hell is J Prius?

2. The file one was just creating a procedure with parameters including (data and filename)
and then you open the file add the "data" and close the file. Just to be sure, I also asked for an input for the data along with the filename and then called the procedure.

3. Oh random generator, so I used a flow chart which made it so much nicer and easier!!!! Randomly generate two numbers - ask the user for an answer - check if the user_answer is correct to num1 + num2 - if it is then add 1 to score, if not score = score and also tries = tries +1 , when tries = 3, break and exit the loop, at the end display the score.

4. This one, I must admit was difficult at first, so I think I used asked the user for the date and then I used a forloop to check if the date matched a date in the 2D array, for that i did something like arrayevents[x, 0] - I think and to find the corresponding seconds something like [x, 3] and then just added that to the local variable (seconds) I had already created. Then, at the end of the count-controlled loop, I just printed the statement as shown.

There you go, gee I cant think of a famous dude uhm......................Brian Cox, yeah that should do for now.

You're welcome.


For the procedure one I just brought the file name and data as parameters I didn’t get an input but I’m sure it’s fine cause it asked for parameter I think. I opened to file to write. Inserted the data. Then closed the file.

for the number one I used a while loop where questions is not equal to 4. I asked for an answer and checked if it was right by randomly generating a total. Then I incremented the questions.
last one was quite hard I think I got it wrong but I took an input of date. And I used selection and just added whatever position the seconds of that array was. Like if it was 05/03/23 total= array[1,3] plus array[2,3]. Something along those lines
so Elon musk I presume you will get a 9
Original post by Guest2091
For the procedure one I just brought the file name and data as parameters I didn’t get an input but I’m sure it’s fine cause it asked for parameter I think. I opened to file to write. Inserted the data. Then closed the file.

for the number one I used a while loop where questions is not equal to 4. I asked for an answer and checked if it was right by randomly generating a total. Then I incremented the questions.
last one was quite hard I think I got it wrong but I took an input of date. And I used selection and just added whatever position the seconds of that array was. Like if it was 05/03/23 total= array[1,3] plus array[2,3]. Something along those lines
so Elon musk I presume you will get a 9


Well I think that the approach you took for the first 2 six marks is correct - last one, I think you will get marks if you 1. input 2. use a for loop 3. compare dates 4. add seconds 5/6. output result?

Oh well, I am sure you did fine - Neils Bohr!
Original post by Blazing_Legend
Well I think that the approach you took for the first 2 six marks is correct - last one, I think you will get marks if you 1. input 2. use a for loop 3. compare dates 4. add seconds 5/6. output result?

Oh well, I am sure you did fine - Neils Bohr!


Thank you Rutherford
Original post by Guest2091
Thank you Rutherford


No problem, Thompson, hope your other exams go well! Good luck!
Reply 269
Original post by Guest2091
Can anyone send what they did for the 6 markers


the random number one was probably the easiest so what i did was:

.score = 0
.for i=1 to 3
.. num1 = random(1,10)
.. num2 = random(1,10)
.. ans = int(input("What is "+str(num1)+" + "+str(num2))
.. if ans == num1 + num2 then
... score = score + 1
.. endif
.next i
.print(score)


The file handling one was:

.procudure WhatEverItWasCalled(text,fileName)
.. myFile = open(fileName.txt)
.. myFile.writeLine(text)
.. myFile.close()
.endprocedure


The 2D array one was

.date = input("Enter date")
.time = 0
.for i=0 to 6
.. if arrrayEvents[i,0] == date then
... time = time + arrayEvents[i,3]
.. endif
.next i
.print("The total time on "+date+" was "+str(time)+" seconds")

(Alternatively you could calculate the number of rows in the 2D array as rows = arrayEvents.length / 4 and then do a for loop from 0 to rows-1)

If u also wanted the input validation 6 marker then there were 3 options you could talk about (only had to pick 2). Range check, Presence check, Type check (Length and format check weren't really applicable to the program)
-For a range check the minimum sum was 1+1=2 and the maximum sum was 10+10 so a range check could check the input was from 2 to 20 inclusive
-For a presence check you just have to check the input isn't empty i.e ans.length != 0
-For a Type check you just have to check the inputs were of the integer data type since whole numbers were being added together


(All the code i have given is in OCR referance language and the first 6 mark programming question was in Section A so NOT marked for syntax so all you needed was the logic. For the 2nd and 3rd questions syntax IS marked obviously depending on the programming language of choice)
(edited 6 months ago)
Original post by epii+1=0
the random number one was probably the easiest so what i did was:

.score = 0
.for i=1 to 3
. num1 = random(1,10)
. num2 = random(1,10)
. ans = int(input("What is "+str(num1)+" + "+str(num2))
. if ans == num1 + num2 then
. score = score + 1
. endif
.next i
.print(score)


The file handling one was:

.procudure WhatEverItWasCalled(text,fileName)
. myFile = open(fileName.txt)
. myFile.writeLine(text)
. myFile.close()
.endprocedure


The 2D array one was

.date = input("Enter date")
.time = 0
.for i=0 to 6
. if arrrayEvents[i,0] == date then
. time = time + arrayEvents[i,3]
. endif
.next i
.print("The total time on "+date+" was "+str(time)+" seconds")

(Alternatively you could calculate the number of rows in the 2D array as rows = arrayEvents.length / 4 and then do a for loop from 0 to rows-1)

If u also wanted the input validation 6 marker then there were 3 options you could talk about (only had to pick 2). Range check, Presence check, Type check (Length and format check weren't really applicable to the program)
-For a range check the minimum sum was 1+1=2 and the maximum sum was 10+10 so a range check could check the input was from 2 to 20 inclusive
-For a presence check you just have to check the input isn't empty i.e ans.length != 0
-For a Type check you just have to check the inputs were of the integer data type since whole numbers were being added together


(All the code i have given is in OCR referance language and the first 6 mark programming question was in Section A so NOT marked for syntax so all you needed was the logic. For the 2nd and 3rd questions syntax IS marked obviously depending on the programming language of choice)

Score=0
Question=0
While question!= 4 :
F=random(1,10)
G=random(1,10)
Total= F +G
Num=int(input whatever
Question=question+1
If num== total
Score =score +1
Else
Score =score +0

Print(total)
Ignore the Syntax errors but how does this look
(edited 6 months ago)
Reply 271
Original post by Guest2091
Score=0
Question=0
While question!= 4 :
F=random(1,10)
G=random(1,10)
Total= F +G
Num=int(input whatever
Question=question+1
If num== total
Score =score +1
Else
Score =score +0

Print(total)
Ignore the Syntax errors but how does this look

I think there's a logic error cuz it will go through the while loop 4 times (cuz Question increments by 1 AFTER asking the question so when asking the 4th question Question = 3 when entering the loop) Looks like 5 out of 6 marks
Reply 272
Regarding some of the other tricky questions the Logic circuit we had to draw was A AND (NOT B) AND C which you could draw in 3 ways: either (A AND (NOT B)) AND C or you could do A AND ((NOT B) AND C) or even (A AND C) AND (NOT B).


the 4 mark programming question about the security system involved more boolean logic


.ActivateAlarm = SystemArmed AND (Windows OR Door)
.if ActivateAlarm then
. SoundAlarm()
.endif


The comparisons of insertion and bubble sort, i put for a difference that insertion sort only requires 1 pass but bubble sort may require multiple passes (so is usually less efficient). For similarities I put that both sort the list from left to right (i.e not divide and conquer) and the runtime for both algorithms depends on how sorted the original list was
Original post by kmody4398
Can wireless networks allow more users to connect to a network?


i wrote whether connecting to wired or wireless still limited by the ip address
Original post by Edgebug
I can list you all the questions if you want

Can you say the questions… it’s going to be the same for my mocks :frown:
Original post by Mariyah Baig
Can you say the questions… it’s going to be the same for my mocks :frown:

If you look on www.smashyourexams.com we have past papers on there. The 2023 papers are still hidden as teachers use them as mocks. Good luck!
Original post by Mariyah Baig
Can you say the questions… it’s going to be the same for my mocks :frown:

Go revise you lazy person

Quick Reply

Latest