Refactored 6-th laboratory work