resulthandler.cs

来自「classic tsp analysis method with c++ !」· CS 代码 · 共 27 行

CS
27
字号
using System;
using HRD.Core;

public class ResultHandler : IResultHandler
{
	public void HandleResult(ChessStep[] steps)
	{
		Console.WriteLine("\r\n");

		for(int i=0; i<steps.Length - 1; i++)
		{
			Console.WriteLine("{0} :", i+1);
			HRD_Helper.ShowLayout(steps[i].layout);
			Console.WriteLine("Move {0} {1}", steps[i].chessmanNum, steps[i].moveMethod);
			Console.WriteLine();
		}

		Console.WriteLine("Got the Answer!");
		HRD_Helper.ShowLayout(steps[steps.Length-1].layout);
	}

	public void HandleInfo(int currentStep)
	{
		Console.Write(".");
	}
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?