namespace五子棋{publicpartialclassForm1:Form{publicForm1(){InitializeComponent();}privatevoidOn_paint(objectsender,PaintEventArgse)//初始化棋盘,画出棋盘{Graphicsgh=e.Graphics;Penmypen=newPen(Color.Black);for(inti=0;