No.3 and No.4 solved code