hono4kami@piefed.social to Programming@programming.devEnglish · edit-214 days agoDon't DRY Your Code Prematurelytesting.googleblog.comexternal-linkmessage-square26fedilinkarrow-up1101arrow-down18file-text
arrow-up193arrow-down1external-linkDon't DRY Your Code Prematurelytesting.googleblog.comhono4kami@piefed.social to Programming@programming.devEnglish · edit-214 days agomessage-square26fedilinkfile-text
minus-squarePieMePlenty@lemmy.worldlinkfedilinkarrow-up24·14 days agoUltimate DRY: just keep refactoring the one method to accept hundreds of parameters and do everything. Add two numbers? DoIt(1, 2); Subtract? DoIt(null, null, 3, 1); Etc.
Ultimate DRY: just keep refactoring the one method to accept hundreds of parameters and do everything.
Add two numbers? DoIt(1, 2);
Subtract? DoIt(null, null, 3, 1);
Etc.
This guy seniors