added assignment code