문제

We want to apply OO to design a process of taking an exam and getting the result. There are two different opinions:

  1. there are 2 objects: questionnaire and algorithm. questionnaire is storing questions and the final result, and the algorithm is for calculating to get the result;

  2. there are 3 objects: questionnaire, algorithm and result, and here, the result is seperated to be one object which is just for storing the result.

My question is which one is a better OO design? Or, what is a correct OO design in this case?

If I want to record a user's answers, is it need to create an object as "Answers" which is connected with questionnare and algorithm?

올바른 솔루션이 없습니다

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top