prestige

TP_Lab1_Main

Apr 18th, 2012
135
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.09 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5.  
  6. namespace TP_Lab1
  7. {
  8.     class Program
  9.     {
  10.         static void Main(string[] args)
  11.         {
  12.             MyClass ob = new MyClass();
  13.             ob.EventHundlerError += new MyClass.Error(ob.PrintError);
  14.             ob.EventHundlerLine += new MyClass.Line(ob.PrintLine);
  15.  
  16.             double a, b, x, step;
  17.             int d, sz;
  18.             Console.Write("a = ");
  19.             a = Convert.ToDouble(Console.ReadLine());
  20.             Console.Write("b = ");
  21.             b = Convert.ToDouble(Console.ReadLine());
  22.             Console.Write("Шаг = ");
  23.             step = Convert.ToDouble(Console.ReadLine());
  24.             Console.Write("Кол-во знаков после запятой = ");
  25.             d = Convert.ToInt32(Console.ReadLine());
  26.             Console.Write("Размер поля = ");
  27.             sz = Convert.ToInt32(Console.ReadLine());
  28.             ob.Title(sz);
  29.             for (x = a; x < b; x+=step)
  30.             {
  31.                 ob.Function(sz,d,x);
  32.             }
  33.         }
  34.     }
  35. }
Advertisement
Add Comment
Please, Sign In to add comment