Planning and Debugging in Elementary Programming