求解,為什么錯(cuò)了
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
??? class Program
??? {
??????? static void Main(string[] args)
??????? {
??????????? int x;
??????????? for(x=1;x<8;x++)
??????????? {
??????????????? int y;
??????????????? for(y=1;y<8;y++)
??????????????? {
??????????????????? if(x == y||x+y==8)
??????????????????? {
??????????????????????? Console.Write("O");
??????????????????? }
??????????????????? else
??????????????????? {
??????????????????????? Console.Write(".");
??????????????????? }
??????????????? }
??????????????? console.writeLine();
??????????? }//請(qǐng)完善代碼
???????????
??????? }
??? }
}
2016-11-17
你的前提是x+y=8