implemented Grid and Printer classes and helpers