working on instance cases 0-5