My code for ECE 590