結果 : algorithm and flow chart with example