Advertisement
kyrathasoft

now

Jul 21st, 2018
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.60 KB | None | 0 0
  1. using System;
  2. /*
  3. from Lesson 6 of C# console programming tutorial series at following URL:
  4. http://williammillerservices.com/windows-c-console-programming/
  5.  
  6. demonstrates use of the .Now property of the DateTime type.
  7. GitHub gist -> https://gist.github.com/kyrathasoft/c8494198fc841cb66898a4017f89ed0c
  8. Pastebin.com ->
  9. */
  10. namespace MyNamespace
  11. {
  12.     class MyClass
  13.     {
  14.         static void Main(string[] args)
  15.         {
  16.             DateTime dtNow = DateTime.Now;
  17.             string p = "The current date and time: ";
  18.             Console.WriteLine(p + " {0}", dtNow.ToString());
  19.         }
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement