Lim initially had $5145, and he withdrew an additional $1040 from his bank account, so he had a total of:
$5145 + $1040 = $6185
Lim divided this total amount equally among his 5 sons, so each son would receive:
$6185 ÷ 5 = $1237
Therefore, each son would receive $1237.