I would like to ask you some questions about dirty code. There are some beginners who coded on a medium project. The code is a very huge ball of mud. They are not advanced programmers. They just know how to use keyboard an a little about java. They just wrote code with 12 000 lines in their main class, though, 6 000 lines belongs to NetBeans itself.
My job is to analyze the code and suggest a good way to maintain the code. My idea is to scrap the project and start a new one with OOP methodology. Recently I collected some notes and ideas about the problem, from this site and some others.
Now, I have the followings questions:
- Should we repair the code, and change it to a OOP? We are now debugging it.
- The code has no comments, no documentation, no particular style of programming, and so forth. Changing it is really expensive and time consuming. What do we can do about this?
- How can I teach them to follow all the rules (commenting, OOP, good code quality, etc.)?
- The code is erroneous and error prone. What can we do? Testing? We almost write two or three A4 papers for correction, but it seems endless.
I should have to say that I am new with them. I think I have broken the rules about adding people too late to the project, as well. Do you think I have to leave them?