General problem-solving algorithm for achieving Euphoric Surprise through verifiable Ideal State Criteria