assignment no2 for rprog005