Rating:
By following the program in a debugger we can find out that every 3 consecutive characters need to be the solutions of a cubic equation. By retrieving the relevant coefficients, we can get the flag.
I don't remember