Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void button1_Click(object sender, EventArgs e)
- {
- string a = textBox1.Text;
- string b = textBox2.Text;
- string c = textBox3.Text;
- string d = textBox4.Text;
- if (a != "" && b != "" && c != "" && d != "")
- {
- label1.Text = "Nezadány všechny údaje";
- }
- else
- {
- int h = int.Parse(a);
- int j = int.Parse(b);
- int k = int.Parse(c);
- int l = int.Parse(d);
- else if (j == 0 && l == 0)
- {
- label1.Text = "Nelze dělit nulou";
- }
- else if ((h / j) < (k / l))
- {
- label1.Text = "<";
- }
- else if ((h / j) > (k / l))
- {
- label1.Text = ">";
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement