+ 1

Code Structuring

I have been working on a very large coding project for months now. I'm finding myself writing/rewriting old code constantly to change how functions operate to be more efficient and add new functionality. My question is: What is the best way to go about structuring my project from the start, before writing any code? Are there any specific design principles that you use that help you in quickly writing large projects?

8th Jul 2019, 7:57 AM
Branam
Branam - avatar
2 Antworten
+ 2
At university, we start by thinking about how the class should interact between them using UML. However, I tend to use another paradigm called extreme programming where you refractor your code very often. Also, you should implement tests to help you. And finally, if you learn along creating this project, it is very normal that you will rewrite portion of your code as you have learnt better way to do so.
8th Jul 2019, 8:05 AM
Drax
Drax - avatar
0
When you work on a large project you can also think about future reusability. Maybe you will have another project where similar functionality is required. If you organize your code into a standalone library that is pretty much independent from the rest of the code, then it may be easier to adapt it to another project's additional requirements with minimum effort. Also make sure everything is well documented :)
8th Jul 2019, 9:28 AM
Tibor Santa
Tibor Santa - avatar