```
public int S1x;

public void Execute()
{
    Random random = new Random();
    S1x = random.Next(14, 146);
    if (S1x % 15 != 0)
        Fix(S1x);
}

public int Fix(int SX)
{                
    Random randomG = new Random();
    SX = randomG.Next(14, 146);
    if (SX % 15 != 0)                               
        Fix(SX); // This is the recursion

    return SX;
}

```

Every few runs it'll work fine, but then I'll try compiling and running it again and it will give me this error:

> 
> System.StackOverflowException was unhandled
>  An unhandled exception of type 'System.StackOverflowException' occurred in mscorlib.dll
>  {Cannot evaluate expression because the current thread is in a stack overflow state.}
> 
> 
> 

And, yes, I know that there is an easier way to do this, but my method of setting a value to equal a random number between 14 and 146, while also ensuring that it is a multiple of 15, should still work nonetheless.

I just am really confused also to why it only gives me the error message sometimes.

So what's wrong with it? Why is it being labeled an infinite recursion even though there is nothing infinite about it?