SoFunction
Updated on 2025-03-08

C# generates small examples of random time


Random random = new Random((int)());
            int i = 0;
            while (i < 100)
            {
                int hour = (2, 5);
                int minute = (0, 60);
                int second = (0, 60);
                string tempStr = ("{0} {1}:{2}:{3}", ("yyyy-MM-dd"), hour, minute, second);
                DateTime rTime = (tempStr);
                (());
                i++;
            }
            ();