---
name: "ACM-Style programming contest"
short: "Practice for the ACM international programming contest"
date: "Sat Jan 27 2001 11:30:00 GMT-0500 (Eastern Standard Time)"
online: false
location: "MC3006"
---
Our ACM-Style practice contests involve answering five questions in three hours. Solutions are written in Pascal, C or C++. Seven years in a row, Waterloo's teams have been in the top ten at the world finals. For more information, see [the contest web page](
Input: Output: asfgjh12dsfgg kj0ab12321BA wdDwkj abBA abcbabCdcbaqwerewq abCdcba### Hard Question: An anagram is a word formed by reordering the letters of another word. Find all sets of anagrams that exist within a large dictionary. The input will be a sorted list of words (up to 4000 words), one per line. Output each set of anagrams on a separate line. Each set should be in alphabetical order, and all lines of sets should be in alphabetical order. A word with no anagrams is a set of anagrams itself, and should be displayed with no modifications.
Input: Output: post post pots stop pots start start stop