daily-email: add 2023-08-06
YAGNI
This commit is contained in:
parent
21081cb0c7
commit
1ef6df5289
16
src/content/daily-email/2023-08-06.md
Normal file
16
src/content/daily-email/2023-08-06.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
---
|
||||
title: >
|
||||
YAGNI
|
||||
pubDate: 2023-08-06
|
||||
permalink: >
|
||||
archive/2023/08/06/yagni
|
||||
tags: []
|
||||
---
|
||||
|
||||
During a recent coding dojo session, we spoke about YAGNI - i.e. "You aren't going to need it".
|
||||
|
||||
In this situation, we discussed how many numbers we should support passing to a method in a calculator application.
|
||||
|
||||
There's no technical limit to how many numbers we can pass, but there may be a requirement where we only need to add or subtract two numbers. In that case, we don't need to calculate three or more numbers, so there's no benefit or value to writing that code.
|
||||
|
||||
If we follow YAGNI, we only write the code we need now. If the requirement changes in the future, we revisit the code and change it as required.
|
Loading…
Reference in a new issue