fork download
  1. namespace TimespanTest
  2. {
  3. class Program
  4. {
  5. static void Main(string[] args)
  6. {
  7. DateTime A = DateTime.Now;
  8. System.Threading.Thread.Sleep(100);
  9.  
  10. TimeSpan B = DateTime.Now.Subtract(A);
  11. System.Threading.Thread.Sleep(1000);
  12. TimeSpan C = DateTime.Now.Subtract(A);
  13.  
  14. TimeSpan D = C.Subtract(B);
  15.  
  16. Console.WriteLine("{0}", D.ToString());
  17.  
  18. return ;
  19. }
  20. }
  21. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cs(7,13): error CS0246: The type or namespace name `DateTime' could not be found. Are you missing a using directive or an assembly reference?
prog.cs(10,13): error CS0246: The type or namespace name `TimeSpan' could not be found. Are you missing a using directive or an assembly reference?
prog.cs(12,13): error CS0246: The type or namespace name `TimeSpan' could not be found. Are you missing a using directive or an assembly reference?
prog.cs(14,13): error CS0246: The type or namespace name `TimeSpan' could not be found. Are you missing a using directive or an assembly reference?
Compilation failed: 4 error(s), 0 warnings
stdout
Standard output is empty