Solution to MCA labs