We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4dc2d43 commit 438aa24Copy full SHA for 438aa24
snippets/csharp/System/Random/Overview/Program.cs
@@ -0,0 +1 @@
1
+Example.Main();
snippets/csharp/System/Random/Overview/next3.cs
@@ -1,12 +1,12 @@
-using System;
2
-
3
-public class Example
+public class Example
4
{
5
public static void Main()
6
7
// <Snippet5>
8
Console.WriteLine("Generating 10 random numbers:");
9
+ Random rnd = new();
+
10
for (uint ctr = 1; ctr <= 10; ctr++)
11
Console.WriteLine($"{rnd.Next(),15:N0}");
12
snippets/csharp/System/Random/Overview/project.csproj
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
- <OutputType>Library</OutputType>
+ <OutputType>exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
0 commit comments