private void Generate_Click(object sender, EventArgs e) { int E = Int32.Parse(eField.Text); int P = Int32.Parse(pField.Text); int Q = Int32.Parse(qField.Text); int D = ModulMath.EuclidEx(E, (P - 1) * (Q - 1)).x; if (!this.Examination(P, Q, E, D)) { return; } this.dField.Text = D.ToString(); this.nField.Text = (P * Q).ToString(); this.w_nField.Text = ((P - 1) * (Q - 1)).ToString(); }
public Form1() { InitializeComponent(); this.pField.Text = 53.ToString(); this.qField.Text = 61.ToString(); this.eField.Text = 71.ToString(); int E = Int32.Parse(eField.Text); int P = Int32.Parse(pField.Text); int Q = Int32.Parse(qField.Text); int D = ModulMath.EuclidEx(E, (P - 1) * (Q - 1)).x; if (!this.Examination(P, Q, E, D)) { return; } this.dField.Text = D.ToString(); this.nField.Text = (P * Q).ToString(); this.w_nField.Text = ((P - 1) * (Q - 1)).ToString(); }