my solutions for codility tests