done with assignment using cases