using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Drawing.Printing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using static System.Windows.Forms.VisualStyles.VisualStyleElement;
namespace WindowsFormsApp4
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load_1(object sender, EventArgs e)
{
}
private void button1_Click(object sender, EventArgs e)
{
//присвоил переменным значения с textbox
double x0 = Convert.ToDouble(textBox1.Text);
double xk = Convert.ToDouble(textBox2.Text);
double dx = Convert.ToDouble(textBox3.Text);
double b = Convert.ToDouble(textBox4.Text);
//цикл
double x = x0;
while (x >= xk)
{
double y = Math.Pow(x, 2) + Math.Tan((5 * x) + b / x);
textBox5.Text += "x=" + x + " ; y=" + y +
Environment.NewLine;
x = x + dx;
}
}
private void label1_Click(object sender, EventArgs e)
{
}
}
}