'Android studio balance with timer (java)

I want to make on button press to start a timer and increment at same time , so let's say the balance is 0.00 i want it when the button is clicked to increase by 0.01 every 5 minutes and when the timer stops it stops increasing and the increment returns to zero



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source