added assign1, nearly done assign 2