using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace c6_1 { public partial class Form1 : Form { public Form1() { InitializeComponent(); } string[] name = new string[4]; private void Form1_Load(object sender, EventArgs e) { name[0] = "john"; name[1] = "tom"; name[2] = "jane"; name[3] = "peter"; } private void button1_Click(object sender, EventArgs e) { label1.Text = "第2位:"+name[1]; } private void button2_Click(object sender, EventArgs e) { label1.Text = ""; for (int i=0;i