Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void button7_Click(object sender, EventArgs e)
- {
- int szam;
- for (int i = 0; i < listBox1.Items.Count; i++)
- {
- szam = Convert.ToInt32(listBox1.Items[i]);
- if(szam % 2 == 0)
- {
- listBox2.Items.Add(szam);
- }
- else
- {
- listBox3.Items.Add(szam);
- }
- }
- listBox1.Items.Clear();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement