solve programming assignment