added descr, rewritten main and more