V
V
vitaly_742018-06-10 04:52:18
Programming
vitaly_74, 2018-06-10 04:52:18

How to write complex classes?

For example, you need to write a class with complex behavior. how to write it in a more optimal way?
now it turns out like this:
1) wrote a draft version, figured out what is needed, what is not needed, what is generally superfluous
2) wrote another one of the same, during the tests, I realized that such an algorithm is bad in itself.
3) has already written a final class.
Is it possible to somehow simplify the writing of complex classes?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton Spirin, 2018-06-10
@vitaly_74

It depends what you mean by complex classes. It is better to try to write simple things. Design principles to help you:
SOLID
KISS
Worse is better

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question