Let the first number be x and the second number be y.
Then, we have:
3x + y = 142 ....(i)
4x − y = 138 ....(ii)
On adding (i) and (ii), we get:
7x = 280
⇒ x = 40
On substituting x = 40 in (i), we get:
3 × 40 + y = 142
⇒ y = (142 − 120) = 22
⇒ y = 22
Hence, the first number is 40 and the second number is 22.