alg_final first try