Problem 2

Parenthesis.pl is my perl script that implements problem 1A. It does so using two algorithms. One uses the logic of my PDA, but written in perl. The other impliments my parser with Parse::RecDescent. The code then tests the two algorithims. Below are the results.
ok 1 - Paren_1 match [[[]]]
ok 2 - Paren_2 match [[[]]]
ok 3 - Paren_1 match (((((((())))))))
ok 4 - Paren_2 match (((((((())))))))
ok 5 - Paren_1 match ((([[[[(((())[][][[]]))[[]]]]]])))
ok 6 - Paren_2 match ((([[[[(((())[][][[]]))[[]]]]]])))
ok 7 - Paren_1 match [[(())]]
ok 8 - Paren_2 match [[(())]]
ok 9 - Paren_1 match [()()[[]][][][][]()(())]
ok 10 - Paren_2 match [()()[[]][][][][]()(())]
ok 11 - Paren_1 match [[[(()[][][[([[([][]()())[]][]][[]])]()])][]][]]
ok 12 - Paren_2 match [[[(()[][][[([[([][]()())[]][]][[]])]()])][]][]]
ok 13 - Paren_1 match (([[(([[(()())[]][]]())())[]][]]())())
ok 14 - Paren_2 match (([[(([[(()())[]][]]())())[]][]]())())
ok 15 - Paren_1 match 
ok 16 - Paren_2 match 
ok 17 - Paren_1 can't match ((]]))]]
ok 18 - Paren_2 can't match ((]]))]]
ok 19 - Paren_1 can't match ((][
ok 20 - Paren_2 can't match ((][
ok 21 - Paren_1 can't match [()()()
ok 22 - Paren_2 can't match [()()()
ok 23 - Paren_1 can't match ([[(]))]
ok 24 - Paren_2 can't match ([[(]))]
ok 25 - Paren_1 can't match (
ok 26 - Paren_2 can't match (
ok 27 - Paren_1 can't match )
ok 28 - Paren_2 can't match )
ok 29 - Paren_1 can't match (()
ok 30 - Paren_2 can't match (()
ok 31 - Paren_1 can't match )(
ok 32 - Paren_2 can't match )(
ok 33 - Paren_1 can't match ]][[][][][]]][[
ok 34 - Paren_2 can't match ]][[][][][]]][[
1..34