Hello, World!

Welcome to the PEG Online Judge. This site was created by members of Woburn Collegiate Institute's Programming Enrichment Group as a resource for competitive programmers everywhere. We also run PEGWiki, a site for information and tutorials of algorithms.

Currently, we have 1029 problems, 280733 submissions, 277 analyses, and support for 15 languages.

If you are new here, register an account and get familiar with the judge by solving A plus B. Alternatively, you can try a random problem that you haven't solved.

Announcements (See All)

Commenting restricted.

by jargon on Oct 27, 2015 - 12:46:00 am UTC
Effective immediately, you must solve aplusb before you may post a comment.

Sorry for the inconvenience.

Woburn Challenge round 1 results are now available!

by Alex on Oct 20, 2015 - 11:28:15 pm UTC
Thank you all for participating! For this round, we had 178 registered competitors from over 29 schools. There were 6 perfect scores in the senior division and 3 perfect scores in the junior division. The problems had varying difficulties, and hopefully there was something that challenged every one of you. If not, look forward to even more challenging puzzles in the rounds to come.

Click here for full results to the contest. Problems, solutions, and test data are now available here.

The senior division prizewinners for this round are:
  • Timothy Li of Don Mills Collegiate Institute ($200)
  • Ahmed Sabie of Glenforest Secondary School ($100)
  • Jeffrey Xiao of University of Toronto Schools ($50)
  • Bill Zheng of Richmond Green Secondary School ($50)
  • Brian Chau of Woburn Collegiate Institute ($50)
The junior division prizewinners for this round are:
  • Sunny Lan of Richmond Hill High School ($50)
  • William Huang of Woburn Collegiate Institute ($25)
  • Jamie Pinheiro of St. Francis Xavier Secondary School ($25)
Congratulations to all of you! These prizes will be distributed as Mastercard gift cards, and we will be contacting your teachers shortly about sending them out. If you haven't won a prize, keep on practicing! We have many more prize opportunities for you throughout the year.

Re-introducing: Woburn Challenge!

by Alex on Oct 06, 2015 - 5:30:32 am UTC
Edit: The contest is over! Many thanks to all of you who participated. We will be posting prizewinners and analyses to all of the problems shortly. Check here, as well as our website periodically!

Edit 2: The problems have been cloned to the main judge. Feel free to submit to them for practice while we work on publishing results and analyses.
Junior Problems: J1, J2, J3, J4
Senior Problems: S1, S2, S3, S4


From the mid-1990s to the early 2000s, the Woburn Challenge was an annual computer programming competition hosted and run by Woburn C.I.'s Programming Enrichment Group. We feel that the time is right to relaunch this free and fun competition for aspiring computer science students in Canada. This year, we're prepared to give out thousands of dollars in prizes to top-performing primary and secondary school students in Canada. If you are a Canadian primary or secondary school student (grades 1-12), you must follow the registration instructions at to be officially eligible for prizes. While only this group of people can receive prizes, everyone is welcome to participate in the online rounds as observers.

This year, we're hosting 4 online rounds (each with a prize pool of over $500) and an in-person invitational finals at the end of the school year (even larger prizes to be announced!). The rounds will take place in October, December, February, April, and early June (for the finals).

Online Round 1

When: Friday, October 16th, 2015 from 3:30 pm to 6:30 pm ET
Where: The PEG Judge interface (
Format: 2 divisions, 3 hours, 4 problems, infinite submissions, and live feedback.
  • Top 3 Junior division winners: $50, $25, $25
  • Top 5 Senior division winners: $200, $100, $50, $50, $50

Full format and rules can be found at:
For more details, visit For questions, email

Good luck!

Pinned Posts

Recent Comments