This question already has an answer here:
Quick background: I'm in an advanced C++ course for a study abroad program. The problem is that I don't have any background in C++. I have a modest C background, but I'm starting to think I have more holes in my knowledge than I knew about.
My problem is that I'm writing really shitty code right now, but the university has an automated testing system that always seems to stump me in some way: does your code meet all the automated tests (no points if not), did you use the naive solution in terms of time or space (you get less points for this), do you have ANY memory errors (usually no points if so).
So, my question is what do you do during development that leads to verifiable, integrated results? Is there a better way to learn and develop so I'm not always cornering myself with features of C/C++? I'm looking to develop a method of software engineering for myself in which I can get full points for these homeworks in less than 10 hours per week (I'm currently spending 15 hours and not getting full points).