Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 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 Polinom_final
- {
- public partial class Form1 : Form
- {
- public Form1()
- {
- InitializeComponent();
- }
- private void button1_Click(object sender, EventArgs e)
- {
- int a = Convert.ToInt32(textBox1.Text);
- // a / 1000 + a / 100 % 10 == a % 100 / 10 + a % 10;
- int b = a / 1000 + a / 100 % 10;
- int c = a % 100 / 10 + a % 10;
- var result = c == b ? textBox2.Text = "True" : textBox2.Text = "False";
- }
- private void Form1_Load(object sender, EventArgs e)
- {
- //textBox1.Text = 9889.ToString();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement