Points A and B are 120 km apart. A motorcyclist starts from A to B along straight road AB with speed 30kmph. At the same time a cyclist starts from B along a road perpendicular to road AB, with a speed of 10kmph. After how many hours will the distance between them be the least?