Using flow graph