Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

intro To Programing exam

  • 07-12-2009 2:39pm
    #1
    Registered Users, Registered Users 2 Posts: 305 ✭✭


    Was jus takin a look at the past exam papers, and they are flyin over me head. The assignments were grand, but this jus looks like absolute gibberish.

    Anyone on the same boat/ able to help at all?!


Comments

  • Registered Users, Registered Users 2 Posts: 26,928 ✭✭✭✭rainbow kirby


    What are you having trouble with?


  • Closed Accounts Posts: 510 ✭✭✭Xhristy


    This post has been deleted.


  • Registered Users, Registered Users 2 Posts: 305 ✭✭Ajfunky


    processing one.. im having problems with the way the questions are asked, because the questions are on strings mainly, which is something i never really grasped.

    Also, im very worried about writing out perfect code on paper, especially since our lecturer said most codes are wrong the first few times! how harsh is the marking?


  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    It's a week away! I havent even thought about it yet!

    But apparently this is the first year they've ever used processing so the past papers mightn't be too much help!

    Also by strings what do you mean?!?!


  • Closed Accounts Posts: 510 ✭✭✭Xhristy


    This post has been deleted.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 334 ✭✭meathawk


    Gianluca Pollastri said that each semi colon isn't all that necessary as he isn't even going to input the code into the processing console, those exam papers were all java, if you have any grasp of the assignments he said it'll be fine. I just got back assignment 5, lucky thing I've already passed intro to programming :cool:


  • Registered Users, Registered Users 2 Posts: 327 ✭✭TDOie


    If the sample papers for processing they gave you are anything like the Java ones its just inheritence and Object orientated programming. Same thing every year just asked a different way or phrased differently. Look over the lecture notes, find where that stuff is mentioned, do it out a few times on paper on till you understand the concepts and where everything is coming from.
    It's fine not understanding things but you'll find you'll generally pickup a lot more siting down and DIYing it.


  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    meathawk wrote: »
    Gianluca Pollastri said that each semi colon isn't all that necessary as he isn't even going to input the code into the processing console, those exam papers were all java, if you have any grasp of the assignments he said it'll be fine. I just got back assignment 5, lucky thing I've already passed intro to programming :cool:

    out of curiosity, how have you passed it?

    If each assignment was worth 8%, you'd need full marks in each...but we're only given grades..and an A is 80% up, A+ is 90%...I havent got Assignment 5 back but I have A's and A+'s in all of the others - I still might only be on 32%...im going with 40% as a pass here!


  • Registered Users, Registered Users 2 Posts: 7,231 ✭✭✭Fad


    TDOie wrote: »
    If the sample papers for processing they gave you are anything like the Java ones its just inheritence and Object orientated programming. Same thing every year just asked a different way or phrased differently. Look over the lecture notes, find where that stuff is mentioned, do it out a few times on paper on till you understand the concepts and where everything is coming from.

    I dont think there are any sample papers.......at least none that I have seen!


  • Registered Users, Registered Users 2 Posts: 334 ✭✭meathawk


    I got an A+ in each assignment, so I assume that means i got the 8% in each one


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    meathawk wrote: »
    I got an A+ in each assignment, so I assume that means i got the 8% in each one

    Not necessarily - an A* is 90% so you have at least 36% - pass by compensation!

    Don't mean to rain on your parade, I'm trying to figure out for myself how I've done too!


  • Closed Accounts Posts: 8,880 ✭✭✭Raphael


    Incorrect, an A+ is 76.67% and upward.


  • Registered Users, Registered Users 2 Posts: 334 ✭✭meathawk


    :mad: my parade has now been officially ruined, however I don't think these 8% assignments work in the same way essays do, i doubt they'd give you 6 percent for an A+.


  • Closed Accounts Posts: 8,880 ✭✭✭Raphael


    No, they'd give you 6-8%, depending on how good of a grade you actually got. An A+ covers that whole range


  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    Sorry, I really didn't mean to ruin that for you!

    I like to work out the minimum mark I could have so if I have higher than that then happy days!

    Does anyone have the gruyere.ucd.ie link for this course, I cleared my history and lost it!


  • Registered Users, Registered Users 2 Posts: 4,039 ✭✭✭Theresalwaysone


    http://gruyere.ucd.ie/2010_courses/10010/

    Theres the course site.

    Anyone have any idea what they could possibly ask on the exam?

    Is it likely to be similar to the assignments?


  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    Thanks, you're a star.

    Apparently Gianluca said there would be some questions in English, some in computer language and apparently some T/F questions, which would be handy!


  • Registered Users, Registered Users 2 Posts: 4,039 ✭✭✭Theresalwaysone


    Excuse my ignorance.

    What are T/F questions?

    And what do you mean by questions IN computer language?

    Ive done all the assignments, got an A in all of them but am absolutely lost as to what this test is about.


  • Registered Users, Registered Users 2 Posts: 334 ✭✭meathawk


    It means True/False questions, I suppose I'll have to get at least 10% out of the exam.


  • Registered Users, Registered Users 2 Posts: 4,039 ✭✭✭Theresalwaysone


    meathawk wrote: »
    It means True/False questions, I suppose I'll have to get at least 10% out of the exam.

    Ah. Sweet. I reckon I need about 15percent from the exam.

    Did he give any clue whatsoever as to whats good to study?

    Im going over some stuff on the processing website at the minute.


  • Advertisement
  • Closed Accounts Posts: 28 doorknob_opener


    On the set of slides from the last lecture, there is a ''course summary'' slide. Some of the topics are written in Italics. Is there any reason for this? A hint perhaps?

    Sorry, this is probably a really silly question!


  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    Possibly, I'll have to have a look at those myself :p

    I don't care if i don't pass the exam, once I pass the module.

    I have a fair idea (I think) so I'm probably just going to wing it :D


  • Closed Accounts Posts: 28 doorknob_opener


    misslt wrote: »
    I don't care if i don't pass the exam, once I pass the module.

    I have a fair idea (I think) so I'm probably just going to wing it :D

    Pretty much my approach too.

    Sure, it'll be grand...


  • Registered Users, Registered Users 2 Posts: 5,570 ✭✭✭RandomName2


    WORST EXAM EVER. Seriously.


    int (you'reScrewed) = 0%;

    ExamPossibleToDo = boolean;
    if (ExamPossibleToDo = true) {
    attempt exam;
    }
    else
    { you're screwed;
    } //not a valid function


  • Closed Accounts Posts: 28 doorknob_opener


    WORST EXAM EVER. Seriously.


    int (you'reScrewed) = 0%;

    ExamPossibleToDo = boolean;
    if (ExamPossibleToDo = true) {
    attempt exam;
    }
    else
    { you're screwed;
    } //not a valid function

    haha....jeez i wanted to cry after that exam. I finished with half an hour left so I left.....didnt want to look at the absolute crap I had written. But so many people were finished extremely early and just waiyed twirling their pencils till the hour was up. Thank God the assignments were worth 40% because that didn't go well at all. But question 2 and exercise A were doable enough so fingers crossed.


  • Registered Users, Registered Users 2 Posts: 334 ✭✭meathawk


    my god excercise 2 was dreadful, the shiiite I wrote about pressing the keyboard, yikes


  • Registered Users, Registered Users 2 Posts: 2,103 ✭✭✭misslt


    Ohh god.

    So i did wing it....winged my way to a fail!

    It was woeful!

    Aww well...its done and I'm finished so roll on tonight :D


  • Registered Users, Registered Users 2 Posts: 7,231 ✭✭✭Fad


    Wish I did more than just the first piece of continuous assessment.......:(


  • Closed Accounts Posts: 8,880 ✭✭✭Raphael


    Fad wrote: »
    Wish I did more than just the first piece of continuous assessment.......:(
    Wow, hope they changed the rule where failing the CA means failing the module.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 7,231 ✭✭✭Fad


    Raphael wrote: »
    Wow, hope they changed the rule where failing the CA means failing the module.

    failed anyway :)


  • Registered Users, Registered Users 2 Posts: 305 ✭✭Ajfunky


    I wish i could do a little code of a plane bursting into flames then crashing, but i guess if i could do that i wouldnt have horribly failed that exam.

    True or false me bolliX! i wrote some awful ****e in that exam..


  • Registered Users, Registered Users 2 Posts: 1,380 ✭✭✭remus808


    They've obviously made it much harder since Fintan's days of glory


  • Registered Users, Registered Users 2 Posts: 188 ✭✭Jack Bracken


    Anyone want to scan the paper and put it up? Really curious what has you all so p***ed, and how it compares to Programming 1.


  • Registered Users, Registered Users 2 Posts: 5,570 ✭✭✭RandomName2


    I can't be bothered to scan it yet; but here's the meat of it:

    'The function, which you will call "sum" should take a single floating point number as an argument, and return a floating point corresponding to the sum of the square roots of all the positive integers that are smaller or equal to the argument. The rest of your code should, continuously: record a String numbers input by the user through the keyboard; when the ENTER or RETURN key is pressed, the complete number typed by the user should be converted into a floating point and input in to the "sum" function; the result of the "sum" function should be printed on the console alongside its argument, and used to control the size of an ellipse drawn on the screen.' :eek:

    And, my favourite....

    In this exercise you have to design a function that operates on arrays (12 marks), and to use it (18 marks). The function, called "sort A" should receive as arguments the array and an integer representing its size, and sort the values contained in the array in decreasing order - you cannot use any predefined Processing sorting function for this task. The rest of the code should: create an array of as many int as the height of the window (minimum 200), fill it with random values in the [0,255] range; sort them using sort A; create a gradient of grey between the top and the bottom of the window, controlled by the values in the array.' :eek::eek:

    And those two were worth 60% of the exam.

    Happy happy days!


  • Registered Users, Registered Users 2 Posts: 5,570 ✭✭✭RandomName2


    In fact, looking at last year's java programming paper I think I would have found it a lot easier...

    EVEN THOUGH I DON'T KNOW JAVA!


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 188 ✭✭Jack Bracken


    Not too bad, but it is more complicated than the Programming 1 paper, which I think is odd. o__O


  • Registered Users, Registered Users 2 Posts: 545 ✭✭✭ravydavygravy


    I can't be bothered to scan it yet; but here's the meat of it:

    'The function, which you will call "sum" should take a single floating point number as an argument, and return a floating point corresponding to the sum of the square roots of all the positive integers that are smaller or equal to the argument. The rest of your code should, continuously: record a String numbers input by the user through the keyboard; when the ENTER or RETURN key is pressed, the complete number typed by the user should be converted into a floating point and input in to the "sum" function; the result of the "sum" function should be printed on the console alongside its argument, and used to control the size of an ellipse drawn on the screen.' :eek:

    And, my favourite....

    In this exercise you have to design a function that operates on arrays (12 marks), and to use it (18 marks). The function, called "sort A" should receive as arguments the array and an integer representing its size, and sort the values contained in the array in decreasing order - you cannot use any predefined Processing sorting function for this task. The rest of the code should: create an array of as many int as the height of the window (minimum 200), fill it with random values in the [0,255] range; sort them using sort A; create a gradient of grey between the top and the bottom of the window, controlled by the values in the array.' :eek::eek:

    And those two were worth 60% of the exam.

    Happy happy days!

    Maybe the standard of CS is slipping, but neither problem strikes me as particularly difficult. I'd hope any first year student could write a basic sorting algorithm (of your choice!), and the first function seems trivial. The only complication is the graphical add-on, but I suspect Processing has utility functions to make these easy.

    EDIT: actually, that came across a bit harsh - obviously sorry that it didn't go well for you -I have no idea how relevant these questions were to the course you were given. I used to tutor many CS students, so I can only go by what we used to teach in first year 6-7 years ago.

    Happy Christmas,

    Dave


  • Closed Accounts Posts: 8,880 ✭✭✭Raphael


    Maybe the standard of CS is slipping, but neither problem strikes me as particularly difficult. I'd hope any first year student could write a basic sorting algorithm (of your choice!), and the first function seems trivial. The only complication is the graphical add-on, but I suspect Processing has utility functions to make these easy.

    EDIT: actually, that came across a bit harsh - obviously sorry that it didn't go well for you -I have no idea how relevant these questions were to the course you were given. I used to tutor many CS students, so I can only go by what we used to teach in first year 6-7 years ago.

    Happy Christmas,

    Dave
    Well, for one thing, intro to programming is a course for non CS students. CS students took Programming 1, which apparently had an easier exam.


  • Registered Users, Registered Users 2 Posts: 1,186 ✭✭✭Nichololas


    That seems a little complicated for a 1st year course, especially one for non-CS students. Sucks to be you guys, I guess.


  • Registered Users, Registered Users 2 Posts: 5,570 ✭✭✭RandomName2


    Maybe the standard of CS is slipping, but neither problem strikes me as particularly difficult. I'd hope any first year student could write a basic sorting algorithm (of your choice!), and the first function seems trivial. The only complication is the graphical add-on, but I suspect Processing has utility functions to make these easy.

    EDIT: actually, that came across a bit harsh - obviously sorry that it didn't go well for you -I have no idea how relevant these questions were to the course you were given. I used to tutor many CS students, so I can only go by what we used to teach in first year 6-7 years ago.

    Happy Christmas,

    Dave

    Well.. um.. yeah. A basic sorting algorithm was an okay prospect. Creating an ellipse? You couldn't get more simple. Indeed pretty much all of the individual steps were feasible enough, at least on paper.

    I actually thought that the questions looked okay when I read them first. But I know how to get the square root of some float, and I also know how to use a sorting algorithm in descending order.

    I don't know how to: return a floating point corresponding to the sum of the square roots of all the positive integers that are smaller or equal to an argument which happens to be the size of a string which is determined by continual keyboard input but only executed when enter or return is pressed (what the **** is return anyway? and what is the name of ENTER (as it isn't a char.... and I don't know the Unix -or whatever- number that it corresponds to.... Was this even covered in the lectures? :confused:) Actually making the sum of all the ints less than or equal to the keyboard input string, a parameter of a shape, was the easy part of that particular question.

    Maybe in several months time I will know how to do those two questions. As it is I don't actually feel at all ashamed getting an F attempting to answer that nonsense.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 334 ✭✭meathawk


    Excercise 2 was just a bitch as was excercise 3, they were meant to be challenging I suppose. They were giving marks away in the first question and excercise 1. I amn't expecting amazing marks but so long as I get a C (with assignments and exam) I don't mind that much. Excercise too was such a joke though, very tough.


  • Registered Users, Registered Users 2 Posts: 545 ✭✭✭ravydavygravy


    Since Its apparent that the course is for non-CS students you do have some of my pity. I think a lot of the problem comes from the way the questions are phrased - they make the problem sound more complicated than it is.

    For example:
    'The function, which you will call "sum" should take a single floating point number as an argument, and return a floating point corresponding to the sum of the square roots of all the positive integers that are smaller or equal to the argument. The rest of your code should, continuously: record a String numbers input by the user through the keyboard; when the ENTER or RETURN key is pressed, the complete number typed by the user should be converted into a floating point and input in to the "sum" function; the result of the "sum" function should be printed on the console alongside its argument, and used to control the size of an ellipse drawn on the screen.'

    All it really says is "read numbers from the keyboard in an infinite loop - each time, take the number, calculate its SUM (as defined below) and use the number to draw an ellipse. SUM is defined as the sum of the square roots of all positive integers <= the input number" - heres my pseudo-code:
    function main()
    {
      while (true)
      {
        // Read string from keyboard
        num_as_string = read_from_keyboard();
    
        // turn it into a float
        num = parseFloat(num_as_string);
        
        // calculate sum
        curr_sum = SUM(num);
    
        // print out the answers
        print num + " results to " + curr_sum;
    
        // draw an ellipse using the two numbers
        draw_ellipse(num,curr_sum);
      }
    }
    
    // Function to calculate SUM 
    function SUM(float number)
    {
        //start with nothing
        result = 0;
    
        // go through the positive integers, one by one, as 
        // long as the current number is <= the input number
        for (int i=1; i<=number; i++)
        {
            // add the square root of this integer to the running total
            result = result + sqrt(i);
        }
    
        // return the final total
        return result;
    }
    

    Like i said, I'm not familiar with Processing, but in Java/PHP/Perl/C#, the actual code wouldn't be much longer than the pseudocode...

    I hope this is helpful - I assume you'll need to repeat at some point...


  • Registered Users, Registered Users 2 Posts: 5,570 ✭✭✭RandomName2


    Since Its apparent that the course is for non-CS students you do have some of my pity. I think a lot of the problem comes from the way the questions are phrased - they make the problem sound more complicated than it is.

    For example:



    All it really says is "read numbers from the keyboard in an infinite loop - each time, take the number, calculate its SUM (as defined below) and use the number to draw an ellipse. SUM is defined as the sum of the square roots of all positive integers <= the input number" - heres my pseudo-code:
    function main()
    {
      while (true)
      {
        // Read string from keyboard
        num_as_string = read_from_keyboard();
    
        // turn it into a float
        num = parseFloat(num_as_string);
        
        // calculate sum
        curr_sum = SUM(num);
    
        // print out the answers
        print num + " results to " + curr_sum;
    
        // draw an ellipse using the two numbers
        draw_ellipse(num,curr_sum);
      }
    }
    
    // Function to calculate SUM 
    function SUM(float number)
    {
        //start with nothing
        result = 0;
    
        // go through the positive integers, one by one, as 
        // long as the current number is <= the input number
        for (int i=1; i<=number; i++)
        {
            // add the square root of this integer to the running total
            result = result + sqrt(i);
        }
    
        // return the final total
        return result;
    }
    

    Like i said, I'm not familiar with Processing, but in Java/PHP/Perl/C#, the actual code wouldn't be much longer than the pseudocode...

    I hope this is helpful - I assume you'll need to repeat at some point...

    Thanks. Hopefully I wont need to repeat due to assignments (3 As, 2 Cs).

    Oh, that should be i--, by the way :D.

    It would have helped had they had practicals (or tutorials) with the course.


  • Registered Users, Registered Users 2 Posts: 545 ✭✭✭ravydavygravy


    Oh, that should be i--, by the way :D.

    Check again, only harder :-)


Advertisement