public void PrintBoard() { for (int i = 0; i < Size; i++) { Console.WriteLine(BoardString.Substring(i * Size, Size)); } }
public string BoardAsString() { string result = ""; for (int i = 0; i < Size; i++) { result += BoardString.Substring(i * Size, Size); result += "\n"; } return(result); }
public void PrintBoardToFile(string filename) { List <string> ls = new List <string>(); for (int i = 0; i < Size; i++) { ls.Add(BoardString.Substring(i * Size, Size)); } File.AppendAllLines(filename, ls, Encoding.Default); }