Main logic maust be written