test program, works perfect, did some cleaning and commenting, still there's work with the output a little bit