fork download
  1. // This is my C# program for variant 07
  2. using System;
  3.  
  4. class MyLab07
  5. {
  6. static void Main()
  7. {
  8.  
  9. double x1 = 2.6;
  10. double x2 = 2.8;
  11. double a = 3;
  12. double b = 6;
  13.  
  14.  
  15. double y1 = Math.Pow(x1, 2); // x1^2
  16. double y2 = Math.Pow(x2, 2); // x2^2
  17. double y3 = y1 + y2;
  18. double y4 = y3 - a;
  19. double y5 = x1 + b;
  20. double c = y4 / y5;
  21.  
  22.  
  23. Console.WriteLine("Результат c = {0:F4}", c);
  24. }
  25. }
  26.  
Success #stdin #stdout 0.03s 28668KB
stdin
Standard input is empty
stdout
Результат c = 1.3488