init code for hw4