I\'m working on problem four of Project Euler and am running into a stackoverflow exception. I\'m not asking for help on solving the problem, I\'d just like it explained
I can't read F# and don't know if your problem is related to this but especially if you're doing something recursive avoid checking for equality to a number, instead try to check for a threshold. For example, instead of testing n = 0, test n <= 0.
Are you compiling in 'Debug' mode or 'Release' mode? Debug mode in VS has tail calls turned off by default (compiler flag "--tailcalls-"), in order to preserve stacks for debugging, but this has the trade-off that you may StackOverflow. You can either switch to 'Release' mode, or
to turn on tail calls with 'Debug' settings.
(Your program runs fine for me with tail calls enabled.)