DEV Community


Posted on

How to apply The Scientific Method in Software Development

Day by day we as developers facing hundreds of technical issues that we have to solve. And, as you know, each of them requires its own solution, but the algorithm to solve an abstract issue is already has been determined many years ago in other science in philosophy. I am talking about the Scientific Method.

The scientific method is a systematic way of learning about the world around us and answering questions. The key difference between the scientific method and other ways of acquiring knowledge are forming a hypothesis and then testing it with an experiment.

The amount of steps in The Scientific Method is varied, but 6 general steps work for me.

  1. Purpose
  2. Research
  3. Hypothesis
  4. Experiment
  5. Analysis
  6. Conclusion

I will explain them step by step.

Purpose / Problem / Question

The easiest and most important as well task is to understand what is the issue you working on and what is the purpose to fix it. There was a lot of cases in my practice that if I dig deep enough into the issue I understood the there was no problem or the problem was diametrically different from the initial description.


Conduct background research. Scroll to the bottom of articles to check the references. Check the author, check the publish date it is extremely important in the modern era where updates coming monthly. Investigate the code around, check the author and commit dates, check attached task and how the feature should work. If after all that you have questions contact the author if possible. Investigate tests if you have such.


Propose a hypothesis. This is a sort of educated guess about what you expect. It is a statement used to predict the outcome of an experiment.


Design and perform an experiment to test your hypothesis. The easiest and most appropriate way to do it is to write a test that detects the issue. While writing tests check only one variable, make them as smaller as you can. In such a way, you could be safe and sure what exactly you test.
Build a test project where you can implement a feature from scratch if possible.


Record observations and analyze what the data means. Try to understand what is the key reason for the issue and how it could be prevented.


The result of the analysis should be described in related ticked and discussed with the team to exclude the possibility of appearance such in the feature.

You probably noticed that The Scientific method is a perfect example of an algorithm and there is no surprise that it was inherited by dozens of other methods. First came to mind is Red-Green-Refactoring method by Robert C. Martin and Observe-Test-Analyze-Repeat method for QA.

Top comments (0)