import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static int howManyGames(int p, int d, int m, int s) { // Return the number of games you can buy int count=0; int tempP=p; while(s>0 &&s>=tempP){ s=s-tempP; count++; tempP=tempP-d; if(tempP