added print function

it uses arrays because smart