示例#1
0
 private void button4_Click(object sender, EventArgs e)
 {
     pizza gav = new pizza(50, 90, 40);
     ost.kolbasa = ost.kolbasa - gav.kolbasa;
     ost.gribi = ost.gribi - gav.gribi;
     ost.testo = ost.testo - gav.testo;
     textBox5.Text = ost.kolbasa.ToString();
     textBox6.Text = ost.gribi.ToString();
     textBox7.Text = ost.testo.ToString();
     string output4 = "Добавлена Деревенская";
     textBox4.Text = output4.ToString();
 }
示例#2
0
 private void button3_Click(object sender, EventArgs e)
 {
     pizza classic = new pizza(100, 100, 100);
     ost.kolbasa = ost.kolbasa - classic.kolbasa;
     ost.gribi = ost.gribi - classic.gribi;
     ost.testo = ost.testo - classic.testo;
     textBox5.Text = ost.kolbasa.ToString();
     textBox6.Text = ost.gribi.ToString();
     textBox7.Text = ost.testo.ToString();
     string output3 = "Добавлена Классика";
     textBox4.Text = output3.ToString();
 }