Hey there! Sign in to join this conversationNew here? Join for free
x Turn on thread page Beta

OCR Computing GCSE- Coursework Tips watch

Announcements
    • Thread Starter
    Offline

    16
    ReputationRep:
    Just finished all of my coursework for computing GCSE.
    I think I have gotten full marks in one and 2 marks off full marks in the second one.
    I can give any tips or pointers.
    Offline

    3
    ReputationRep:
    Well Done! I found them really challenging. Did you have the computer booking system app inventor task?
    Offline

    8
    ReputationRep:
    (Original post by Undec)
    Just finished all of my coursework for computing GCSE.I think I have gotten full marks in one and 2 marks off full marks in the second one.I can give any tips or pointers.


    hello gj, i'm stuck on the A453 programming task; I have no idea how to code for task 2 and 3, I think I've done task 1 correctly. Any help would be appreciated.
    Offline

    3
    ReputationRep:
    (Original post by dRaGoN2509)
    hello gj, i'm stuck on the A453 programming task; I have no idea how to code for task 2 and 3, I think I've done task 1 correctly. Any help would be appreciated.
    You need to learn how to read and write to text files
    Offline

    6
    ReputationRep:
    (Original post by Undec)
    Just finished all of my coursework for computing GCSE.
    I think I have gotten full marks in one and 2 marks off full marks in the second one.
    I can give any tips or pointers.
    Any tips for full marks on A452?
    Offline

    8
    ReputationRep:
    (Original post by qwertyfat)
    You need to learn how to read and write to text files
    yes I know that but I tried to create a code in Python for it but it doesn't work correctly. Can someone give me some advice on how to do this?
    Offline

    2
    ReputationRep:
    (Original post by dRaGoN2509)
    yes I know that but I tried to create a code in Python for it but it doesn't work correctly. Can someone give me some advice on how to do this?
    For task 2 you need to write the name and score to a textfile on a new line.
    Here is a basic idea of how you'd go about doing that.
    Code:
    textfile = open(filename,"a+") #Opens textfile as append
    textfile.write("text\n") #Writes text and new line
    textfile.close() #Closes textfile
    In the write bit, you could write it to the textfile like "name|score"


    However for task 3 I really can't really go into too much detail about that...
    But I'd go about it by going through each line of the text file, splitting it by the "|" and appending that to a list of some sort.
    Then when it comes to sorting the list I can't go into too much detail but I'd use the SORTED function. I'd recommend you follow some documents/wiki guides for it such as this: https://wiki.python.org/moin/HowTo/S...dule_Functions
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by Paul Atreides)
    Any tips for full marks on A452?
    I completed all of the 3 tasks. But I spent extra time taking each piece of code and annotating it and saying what it does and how it works. Also in the improvement/evaluation part I wrote in a lot of detail how I did the task what I had problems in (described why they occurred) and how i resolved them. I also did a lot of testing of the programs.
    Offline

    10
    ReputationRep:
    Need help on A453 too, I dont know if this is the same coursework as you but I have to program a speed camera type device in python. Can anyone help me with task 2 and 3? Thanksx
    Offline

    2
    ReputationRep:
    (Original post by NoodleGCSEFOOD)
    Need help on A453 too, I dont know if this is the same coursework as you but I have to program a speed camera type device in python. Can anyone help me with task 2 and 3? Thanksx
    Looks like task 2 is about saving a list of vehicles with non-standard registrations which are exceeding the speed limit to a file.

    So, from task 1 it looks like you should have already coded the basics of checking the speed of each vehicle.
    It looks like you should be using a list to store the registrations and time taken to travel for each vehicle, like so:
    Code:
    data = (["registration1", 10], ["registation2", 7], ["registation3", 8])
    Now, it looks like while you are going through that list, you must check if the registration plate is standard, and write it to a file if it isn't.
    For this, I would certainly use "regex" to check if the registration string matches the standard. It looks like I can't really give out too much for that without cheating, so I'd recommend you read up on it here: https://docs.python.org/3/howto/regex.html or have a look elsewhere.

    Here's an example of how to check a postcode is non-standard in the UK e.g. LS18 4AA:
    Code:
    if not re.match("^[A-Z][A-Z]\d\d \d[A-Z][A-Z]$", postcode):
        print("Postcode is non-standard")
    Obviously, you'll have to adjust that for the format of a vehicle registration for yourself.

    Then, once you've determined it's non-standard, you will to save the data to a file.
    As an example, you can write it to a text file like this:
    Code:
    file = open("textfile.txt","a") #Opens in append mode
    file.write(string +"\n") #Write to file and create new line
    file.close() #Close file

    For task 3, it looks like it's about matching up the registration with name and details from another file.
    While you are checking each vehicle for the list, you would have to add a FOR loop for each entry of the file to check if it equals the registration of the vehicle exceeding the speed limit.
    It also looks like you'd then have to use that data to save to another file with information about the registration, speed, name and address.
    Offline

    10
    ReputationRep:
    (Original post by thebaco123)
    Looks like task 2 is about saving a list of vehicles with non-standard registrations which are exceeding the speed limit to a file.

    So, from task 1 it looks like you should have already coded the basics of checking the speed of each vehicle.
    It looks like you should be using a list to store the registrations and time taken to travel for each vehicle, like so:
    Code:
    data = (["registration1", 10], ["registation2", 7], ["registation3", 8])
    Now, it looks like while you are going through that list, you must check if the registration plate is standard, and write it to a file if it isn't.
    For this, I would certainly use "regex" to check if the registration string matches the standard. It looks like I can't really give out too much for that without cheating, so I'd recommend you read up on it here: https://docs.python.org/3/howto/regex.html or have a look elsewhere.

    Here's an example of how to check a postcode is non-standard in the UK e.g. LS18 4AA:
    Code:
    if not re.match("^[A-Z][A-Z]\d\d \d[A-Z][A-Z]$", postcode):
        print("Postcode is non-standard";)
    Obviously, you'll have to adjust that for the format of a vehicle registration for yourself.

    Then, once you've determined it's non-standard, you will to save the data to a file.
    As an example, you can write it to a text file like this:
    Code:
    file = open("textfile.txt","a";) #Opens in append mode
    file.write(string +"\n";) #Write to file and create new line
    file.close() #Close file
    Thanks for this even though I barely understand the code principle, have you got skype where we can have a conversation about this? Or at least share my code and to start implementing task 2 and 3. I got an A on the last coursework and dont want to get a bad mark on this
    Offline

    2
    ReputationRep:
    (Original post by NoodleGCSEFOOD)
    Thanks for this even though I barely understand the code principle, have you got skype where we can have a conversation about this? Or at least share my code and to start implementing task 2 and 3. I got an A on the last coursework and dont want to get a bad mark on this
    Sent you a PM.
    Offline

    0
    ReputationRep:
    can i get some help for a453? task 2 and task 3 i have got so far and am having trouble putting the reg plates that are wrong and speed into a file and havn't even started task 3 so any help would be appreciated please pm me
    Offline

    8
    ReputationRep:
    (Original post by Cheshirecatt)
    can i get some help for a453? task 2 and task 3 i have got so far and am having trouble putting the reg plates that are wrong and speed into a file and havn't even started task 3 so any help would be appreciated please pm me
    same^ please pm me as well as I really need help with A453. Thanks.
    Offline

    2
    ReputationRep:
    anyone done the arithmetic quiz for a453??


    Posted from TSR Mobile
    Offline

    13
    ReputationRep:
    have you done the Caesar cipher? need serious help with that. and making an algorithm is really tough
    Offline

    2
    ReputationRep:
    (Original post by dRaGoN2509)
    same^ please pm me as well as I really need help with A453. Thanks.
    Done.

    (Original post by lilsadkitty)
    anyone done the arithmetic quiz for a453??


    Posted from TSR Mobile
    What do you need help with?

    (Original post by ZS1)
    have you done the Caesar cipher? need serious help with that. and making an algorithm is really tough
    Please elaborate what the task is asking you to do. Do you want to encode it in Caesar cipher? Decode it?
    Offline

    13
    ReputationRep:
    (Original post by thebaco123)
    What do you need help with?



    Please elaborate what the task is asking you to do. Do you want to encode it in Caesar cipher? Decode it?
    The task wants me to encrypt the message in caesar cypher and wants me to decrypt it too.
    Offline

    2
    ReputationRep:
    (Original post by illuminatio)
    hey bro if its possible could you send me the code for task two and three because i have finished task one, but i am really stuck on task two and three and i only have one week left to finish.
    Doesn't look like he will send you his full code, but if you tell us the task and what you're struggling with we can try to help you out.
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by lilsadkitty)
    anyone done the arithmetic quiz for a453??


    Posted from TSR Mobile
    What are you stuck on with this one? I can explain it to you how you could go around doing it
 
 
 
Reply
Submit reply
Turn on thread page Beta
Updated: April 19, 2017
Poll
Do you like carrot cake?

The Student Room, Get Revising and Marked by Teachers are trading names of The Student Room Group Ltd.

Register Number: 04666380 (England and Wales), VAT No. 806 8067 22 Registered Office: International House, Queens Road, Brighton, BN1 3XE

Write a reply...
Reply
Hide
Reputation gems: You get these gems as you gain rep from other members for making good contributions and giving helpful advice.