intial code and structure