Their relative speed is the sum of 60 and 40 or 100km/hr. They will travel the 150km in 1.5 hrs.When two object approach each other, the closing speed is just the sum of the speeds, therefore, the closing speed is your case is 100kph.
Just take the distance of 150 km and divide by 100 to get 1.5 hours
checking:
the car going 60 will have traveled 60*1.5 = 90 km
the car going 40 will have traveled 40*1.5 = 60 km
the sum of the distances = 90+60 = 1.5 hours
So they will meet in 1.5 hours.