Computer Science Canada

Got Owned on CCC

Author:  Shardul [ Tue Feb 24, 2009 6:45 pm ]
Post subject:  Got Owned on CCC

Very Happy
Well can't say I didn't expect the bad but I expected better. I only got the first question on the damn junior contest which was basic addition and multiplication Rolling Eyes . I am not stupid or anything (well not really stupid). I got a 98 % in Grade 11 Compsci yet I died on the contest. Sad

My question is what are you basically supposed to know to do good on the damn contest. I know it is pretty general and too abstract for you to help me a lot but in general, what do you need to know to do well on these contests (talking about like >40 score). I know some people haven't written the contest so keep it abstract as possible. Smile

Oh btw: first time writing contest (was sick on contest day in Grade 10)

Author:  nike52 [ Tue Feb 24, 2009 7:02 pm ]
Post subject:  Re: Got Owned on CCC

Practice thinking and coding a solution quickly.
Practice a lot. Start on the J1 questions then master the next ones.

http://access.mmhs.ca/ccc/index.htm

Author:  Euphoracle [ Tue Feb 24, 2009 7:03 pm ]
Post subject:  RE:Got Owned on CCC

Your mark in your compsci class does reflect how you'll do on the CCC. People who got 95+ in compsci failed the CCC this year, and me, who got an 80 or something, did the best (but still bad, because I failed at comprehending S2, and didn't get to finish S5). Each level usually has a theme to it. Junior is usually about simple math for S1/S2, and recursion in S3/S4, and S5 is usually a mixture of recursion and case-structure problem solving. The senior focuses on graph searching, node trees, dynamic programming, and some more recursion. The senior level one is much harder than the junior one on average, but the final (5) problem has been known to be the same on both.

Author:  Tony [ Tue Feb 24, 2009 7:11 pm ]
Post subject:  RE:Got Owned on CCC

http://dwite.org/ -- once a month, every month leading up to CCC. Actually, if there is enough interest, we might also have a few bonus rounds in April/May/June.

Author:  A.J [ Tue Feb 24, 2009 7:33 pm ]
Post subject:  Re: Got Owned on CCC

well, on behalf of everyone in Waterloo Collegiate, I would like to ask you to please go ahead with making the bonus DWITE's Very Happy

they are fun, and good practice Smile

Author:  SJ [ Tue Feb 24, 2009 8:17 pm ]
Post subject:  RE:Got Owned on CCC

programming contests is problem solving. a few things you can do in general to improve:

1. do math/logic puzzles. don't just understand the solution, but HOW one goes abut finding the solution.

2. learn algorithms and data structures. There are a lot of online resources (videos, wiki, etc)

3. most importantly, practice! do old contests, online contests, online training, etc.

during the contests, always try to do the problem on paper first, do a sample case manually, lay out each step of how you solved it, then form an algorithm, finally code it up. Once you get used to this you'll be able to get 40+ easily.

you still have time, so work hard and I'm sure you'll do great next year!

Author:  Insectoid [ Tue Feb 24, 2009 8:45 pm ]
Post subject:  RE:Got Owned on CCC

I find people may do exceptionally well in school but fail in contests because schools focus more on syntax (as far as my experience can tell) while contests are all about algorithms and problem solving. For me, grade 11 was a repeat of grade 10, just in a different language. So much so that in fact I was able to look up my old assignments, convert them to java and hand them in. What I do is think of an interesting problem that provides a challenge, like a calculator that reads in an equation as a string and outputs the answer according to bedmas. Then I do it.

My biggest issue is when I can't understand the question, due to mass variable usage in the question and so much notation that I forget what stands for what and whatnot. Some questions I have to read a dozen times before I find out what I'm supposed to do.

Author:  Tony [ Tue Feb 24, 2009 8:54 pm ]
Post subject:  Re: RE:Got Owned on CCC

insectoid @ Tue Feb 24, 2009 8:45 pm wrote:
My biggest issue is when I can't understand the question...

If that's even the case for DWITE, you can ask Dan or myself to clarify via IM / email / IRC.

Author:  zero-impact [ Tue Feb 24, 2009 8:54 pm ]
Post subject:  RE:Got Owned on CCC

For me it is the same as what insectoid said. I basically epic failed at understanding S2 and I am top of my class.

Author:  DanielG [ Tue Feb 24, 2009 9:04 pm ]
Post subject:  RE:Got Owned on CCC

S2 was weird, my main problem with it wasn't understanding it, but stupid mistakes with my coding (got it right though in the end).... I think.

Author:  jcollins1991 [ Tue Feb 24, 2009 9:06 pm ]
Post subject:  Re: RE:Got Owned on CCC

Euphoracle @ Tue Feb 24, 2009 7:03 pm wrote:
but still bad, because I failed at comprehending S2, and didn't get to finish S5


zero-impact @ Tue Feb 24, 2009 8:54 pm wrote:
For me it is the same as what insectoid said. I basically epic failed at understanding S2 and I am top of my class.


what didn't you get about S2? i think S3 and S4 would have taken me the longest if i had gotten around to them...

Author:  Euphoracle [ Tue Feb 24, 2009 9:09 pm ]
Post subject:  RE:Got Owned on CCC

S3 and S4 I did in under an hour total, but S2 consumed the majority of my time, I lost track of it, and then I couldn't finish S5 (or get much started on) Sad

Author:  saltpro15 [ Tue Feb 24, 2009 9:48 pm ]
Post subject:  RE:Got Owned on CCC

Compete in the DWITE's, learn algorithms and you will start to recognize patterns to these problems, they are very different than in-class work. but that's the point, they're supposed to make you think Wink

Author:  CodeMonkey2000 [ Wed Feb 25, 2009 12:32 am ]
Post subject:  RE:Got Owned on CCC

This year's contest was brutal. I answered 4 questions, but I have a bad feeling about all of them.

Author:  chili5 [ Wed Feb 25, 2009 6:07 am ]
Post subject:  RE:Got Owned on CCC

Okay, that contest was mean. I only got 1 question right. Now that is a bit discouraging. Sad I did rather well on DWITE (I think), and sucked at CCC. Sad I got s2 wrong, and didn't understand the theory behind the last 3. Sad

Author:  Insectoid [ Wed Feb 25, 2009 12:35 pm ]
Post subject:  RE:Got Owned on CCC

Well, apparently I lost some marks due to prompting/output formatting on questions that didn't have specific prompting instructions (on the junior questions). I feel it's retarded to have to have exact output format.

Author:  saltpro15 [ Wed Feb 25, 2009 12:38 pm ]
Post subject:  RE:Got Owned on CCC

insectoid, i did that too, but I caught it before I handed in my question, are you talking about J1 where it has to get the digits on the same line instead of the line underneath your put statement?

Author:  phleet [ Wed Feb 25, 2009 1:05 pm ]
Post subject:  RE:Got Owned on CCC

Go do practice problems on UVa:

http://icpcres.ecs.baylor.edu/onlinejudge/

The problems there vary greatly in difficulty, but I would say the majority of them are harder than S1-S3 and there are many harder than anything that's ever been on CCC. UVa works like Dwite, but it's constantly running and does not tell you how many test cases you got right - it's all or nothing.

There's also the Sphere
http://www.spoj.pl/

Which I haven't touched much, but I know that Hanson trained himself on this. He's ranked worldwide there, so yeah. I haven't really touched this because the variety of problems are much different than those on CCC - more concerning arcane mathematics and programming in languages I have little interest in learning (whitespace).

Author:  DanielG [ Wed Feb 25, 2009 2:37 pm ]
Post subject:  RE:Got Owned on CCC

our teacher hasn't finished marking yet, but so far highest is 29... we all failed....(xiao hasn't been marked yet and mine has some wierd problem not at my fault so I would probably do better than 15....)

Author:  saltpro15 [ Wed Feb 25, 2009 2:46 pm ]
Post subject:  Re: Got Owned on CCC

found this
Canadian Computing Competition 2008
Stage 1 Junior Average (Mean) 29.56
Stage 1 Senior Average (Mean) 22.81
Junior Certificate Cutoff 44
Senior Certificate Cutoff 33
Number of Competitors 1624

any ideas as to what the cutoffs will be this year? I would think lower considering how difficult the problems were

Author:  Euphoracle [ Wed Feb 25, 2009 3:52 pm ]
Post subject:  RE:Got Owned on CCC

Haha, S3 I forgot to add in the built in friend structure. D'oh. And there's my memory showing off it's stripes. Oh well, I did horribly on this contest, but that's ok, because I did eventually solve them all at home. Apparently, I can't work timed like that :p

Author:  A.J [ Wed Feb 25, 2009 3:55 pm ]
Post subject:  Re: Got Owned on CCC

the certificate cutoffs will certainly be lower, and sol will the stage 2 cutoffs

The stage 2 cutoff will probably be around 55ish (maybe even lower).

Author:  Insectoid [ Wed Feb 25, 2009 5:27 pm ]
Post subject:  RE:Got Owned on CCC

In the 'welcome to CCC Good luck' or whatever problem I failed to realize that 7 letters per line may result in more than 2 lines of words, and mine only works at 15 or more letters per line. Unfortunately, no test case ran a number >= 15. Sad. I got zip on that question.

@saltpro15, I think it was the fish one, I put

X trout, Y northern pike, Z northern pickeral

which was right, but for the max number of combinations, I had just the number, instead of a "Max combinations: A"

That question was actually dirt simple, I used a triple nested for loop and an if statement. That was also the one on which I was docked for input, because the question showed the input as

code:

1
2
3
2


while previous questions had in the sample:

code:

Number 13: 9
Number 14: 8
number 15: 0


So I figured I would format everything exactly as the sample input. Bad idea. Well, now I know for next time.

I did notice it was much harder than last year's, last year the first 4 junior questions were ridiculously easy, this year you had to think from J2 on. Senior was just insane.

Author:  saltpro15 [ Wed Feb 25, 2009 5:36 pm ]
Post subject:  RE:Got Owned on CCC

My J2 was behaving very strangely... I brute forced it and got it to output all possible combos correctly, but for the amount of each type of fish the answers would overlap somehow Sad maybe I'll post it this weekend, see if anyone knows what I'm missing

Author:  chili5 [ Wed Feb 25, 2009 5:57 pm ]
Post subject:  RE:Got Owned on CCC

Ouch I only got 6/75. Sad

Author:  DanielG [ Wed Feb 25, 2009 6:10 pm ]
Post subject:  RE:Got Owned on CCC

I got 15/75 (only got points on Q2, which I did in turing), but that's because for some reason my code is doing problems the teachers IDE/perhaps input files (since I used freopen). anyway, as it isn't my fault (worked on my computer and is not a mistake) I will probably get more than that

Author:  saltpro15 [ Wed Feb 25, 2009 6:13 pm ]
Post subject:  RE:Got Owned on CCC

@DanielG
this is why I used Turing Very Happy
but next year, c++ for sure

Author:  Analysis Mode [ Wed Feb 25, 2009 6:59 pm ]
Post subject:  Re: Got Owned on CCC

hmm, four people from my school got a score of 60 or more on Senior. IF I were to harbor a guess, cutoff would be between 55 to 65. don't ask about my score, I FUBARed really badly.

S1 - i outputted all the number that satisfied the range and the count instead of just the count
S2 - don't know why I didn't get this
S3 - failed to: 1) read the problem statement, and didn't output "No Path" 2) left out one edge.
S4 - used the right algorithm, but: 1) started at all the pencil cities and tried to reach the end instead of starting at the destination and going from there.
S5 - didn't bother to code the solution that apparently gets 6/15 (the pure brute force solution in which you keep a 2D array and add bitrates to it for every circle).

Author:  saltpro15 [ Wed Feb 25, 2009 7:55 pm ]
Post subject:  RE:Got Owned on CCC

Sad is there any way for me to get a copy of this year's senior questions? I really would like to know what you all are talking about :p

Author:  chili5 [ Wed Feb 25, 2009 8:50 pm ]
Post subject:  RE:Got Owned on CCC

http://access.mmhs.ca/ccc/index.htm

Smile

Author:  saltpro15 [ Wed Feb 25, 2009 8:58 pm ]
Post subject:  RE:Got Owned on CCC

thanks chili

Author:  chili5 [ Wed Feb 25, 2009 8:59 pm ]
Post subject:  RE:Got Owned on CCC

No problem!

Wow S1 was a 3 star senior. The highest level question from the CCC i ever looked at was 2 star junior. :-S However dwite was hard. But omg that was hard. Sad

Author:  saltpro15 [ Wed Feb 25, 2009 9:03 pm ]
Post subject:  RE:Got Owned on CCC

argh im going to go jump into lake erie I can't believe I made that little mistake in J2 !!!!!!!!!!!!!!!!!!!!!!!! and J4 seems so easy now Sad

Author:  Shardul [ Wed Feb 25, 2009 9:06 pm ]
Post subject:  Re: Got Owned on CCC

Yeah, I found the contest to be hard this year. I have never written the CCC before but I looked at the previous contests so I totally didn't go in unprepared and on the contests that I looked beforehand, I managed to get 2 / 5. But I only got 1 on the CCC Junior. Sad

Also, anybody know how the CCC is marked? Cuz I had the junior number 4 working for all cases below 30 (lots of inefficient ifs : P) but I deleted it in my quest to find a proper algorithm. Oh well, next year it is, hopefully before university applications : P

Author:  saltpro15 [ Wed Feb 25, 2009 9:09 pm ]
Post subject:  RE:Got Owned on CCC

CCC round 1 is marked by our CS teachers, there's usually 5 test cases worth 3 marks each for a total of 15 per question, it's different sometimes though.

Author:  Shardul [ Wed Feb 25, 2009 9:11 pm ]
Post subject:  Re: Got Owned on CCC

Sad Wasted marks and wasted opportunities

Author:  saltpro15 [ Wed Feb 25, 2009 9:17 pm ]
Post subject:  RE:Got Owned on CCC

hey, I lost 15 marks because I did
for k : 1..something
instead of for k : i .. something
!!!

Author:  DanielG [ Wed Feb 25, 2009 9:18 pm ]
Post subject:  RE:Got Owned on CCC

just found out what my problem was for Q1-5 (excluding 2 which I did in turing),
I used freopen which changed file standart input to file input, but it also caused system("pause") to fail (I used a different IDE which didn't need that) and so the teacher couldn't see the output (since the window close to quickly).
hopefully, my teacher will remark it (as 15/75 is far from a pass by my standards).

EDIT: add clarification as to mistake

Author:  Tomszy [ Wed Mar 11, 2009 8:28 am ]
Post subject:  Re: Got Owned on CCC

Well, you shouldn't have been using system("pause") anyway. Since it's standard output, your teacher should have been redirecting the output to a file to mark it. Our school used some batch files to automatically mark all the test cases for C/C++ submissions. Off the top of my head, I can't remember the exact syntax to redirect output.

Author:  Dan [ Wed Mar 11, 2009 12:00 pm ]
Post subject:  Re: Got Owned on CCC

Tomszy @ 11th March 2009, 8:28 am wrote:
Off the top of my head, I can't remember the exact syntax to redirect output.


In a unix envoriment it is ">> filename.txt" after what ever comand to appened the std out to the file filename.txt. You can use just one '>' to override the file competly. Here is a good page with more info: http://www.mathinfo.u-picardie.fr/asch/f/MeCS/courseware/users/help/general/unix/redirection.html


If you are running a process from with in a program, most langues allow you to cature the std out of a process too, witch is how the DWITE does it for the std error and out streams however we have std out disbaled for reporting to the students.


In any case you are right, system("pause"), should not be used in your programs to keep the window open. The teacher should have been runing the programs from the console, and it is rdiculess if they did not give you full marks becues they did not know how to keep the window open.


: