When a number is divided by 42 the remainder is 39 and when it is divided by 36 the remainder is 33.find the number.