Date and time continuous C# Exercise - C# Programming Course


Date and time continuous


Create a program that shows the current time in the top-right corner of the screen with the format:


The program should pause for one second and then display the time again in the same location.

 Example Code

using System;
using System.Threading;
class DateAndTimeContinuos
    static void Main()
        while (true)
            string time = DateTime.Now.ToLongTimeString();

            Console.SetCursorPosition(72, 1);


Juan A. Ripoll - Programming Tutorials and Courses © 2024 All rights reserved.  Legal Conditions.