in reply to Can Perl do 2D matching?

Can you be more specific? There are a lot of modules in CPAN. Some of them might be exactly what you're looking for.