fork download
  1. usingSystem;
  2.  
  3. usingSystem.Collections.Generic;
  4.  
  5. usingSystem.Linq;
  6.  
  7. usingSystem.Text;
  8.  
  9. usingSystem.Threading.Tasks;
  10.  
  11. namespace ConsoleApplication36
  12.  
  13. {
  14.  
  15. classProgram
  16.  
  17. {
  18.  
  19. staticvoidMain(string[] args)
  20.  
  21. {
  22.  
  23. double x, S, h, Integ, a, b, n;
  24.  
  25. a = 0; b = 3; n = 100; S = 0;
  26.  
  27. h = (b - a) / n;
  28.  
  29. for (x = a; x <= (b - h); x += h)
  30.  
  31. S += Math.Asin(Math.Sqrt(x / (1 + x)));
  32.  
  33. Integ = h * S;
  34.  
  35. Console.WriteLine("Iнтеграл = " + Integ);
  36.  
  37. Console.ReadKey();
  38.  
  39. }
  40.  
  41. }
  42.  
  43. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.c:1:1: warning: data definition has no type or storage class
 usingSystem;
 ^~~~~~~~~~~
prog.c:1:1: warning: type defaults to ‘int’ in declaration of ‘usingSystem’ [-Wimplicit-int]
prog.c:3:12: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘.’ token
 usingSystem.Collections.Generic;
            ^
prog.c:5:12: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘.’ token
 usingSystem.Linq;
            ^
prog.c:7:12: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘.’ token
 usingSystem.Text;
            ^
prog.c:9:12: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘.’ token
 usingSystem.Threading.Tasks;
            ^
prog.c:11:1: error: unknown type name ‘namespace’
 namespace ConsoleApplication36
 ^~~~~~~~~
prog.c:13:1: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
 {
 ^
stdout
Standard output is empty