What's the difference between an Algorithm and a Design Pattern

后端 未结 12 904
轮回少年
轮回少年 2020-12-24 13:54

I was searching for \"Undo/Redo algorithms\" and found something marked as a duplicate, but the duplicate was a request for a \"Undo Design Pattern\". I\'d really like an al

12条回答
  •  渐次进展
    2020-12-24 14:40

    Design patterns:

    • a solution to a common but generic problem.
    • general solution to general problem.
    • often have to be implemented each time it is used.

    Algorithm:

    • specific set of steps you can follow to answer particular problem.
    • implemented directly to solve specific problem.

提交回复
热议问题