A number is such that when divided by 3, 5, 6, or 7 it leaves the remainder 1, 3, 4, or 5 respectively. Which is the largest number below 4000 that satisfies this property?
(a) 3358
(b) 3988
(c) 3778
(d) 2938