Prototipo funzionante
This commit is contained in:
parent
dec3345304
commit
3656218611
26
Program.cs
26
Program.cs
@ -4,6 +4,30 @@ class Program
|
||||
{
|
||||
static void Main(string[] args)
|
||||
{
|
||||
Console.WriteLine("Hello, World!");
|
||||
//dichiarazione variabili
|
||||
Random rnd = new Random();
|
||||
int random, numero;
|
||||
//inizializzazione
|
||||
random = rnd.Next(1, 100);
|
||||
//richiesta input e sanitization
|
||||
do{
|
||||
do{
|
||||
Console.WriteLine("Inserire un numero: ");
|
||||
numero=Convert.ToInt32(Console.ReadLine());
|
||||
if (numero<=0) {
|
||||
Console.WriteLine("Il numero non è né negativo né zero, riprova");
|
||||
}
|
||||
}
|
||||
while(numero<=0);
|
||||
//controllo se il numero è stato indovinato
|
||||
if (numero>random){
|
||||
Console.WriteLine("Il numero inserito è troppo grande, riprova");
|
||||
}
|
||||
else if (numero<random){
|
||||
Console.WriteLine("Il numero inserito è troppo piccolo, riprova");
|
||||
}
|
||||
}
|
||||
while (numero!=random);
|
||||
Console.WriteLine("Congratulazioni! Hai indovinato il numero");
|
||||
}
|
||||
}
|
||||
|
||||
BIN
bin/Debug/net8.0/rng_game
Executable file
BIN
bin/Debug/net8.0/rng_game
Executable file
Binary file not shown.
23
bin/Debug/net8.0/rng_game.deps.json
Normal file
23
bin/Debug/net8.0/rng_game.deps.json
Normal file
@ -0,0 +1,23 @@
|
||||
{
|
||||
"runtimeTarget": {
|
||||
"name": ".NETCoreApp,Version=v8.0",
|
||||
"signature": ""
|
||||
},
|
||||
"compilationOptions": {},
|
||||
"targets": {
|
||||
".NETCoreApp,Version=v8.0": {
|
||||
"rng_game/1.0.0": {
|
||||
"runtime": {
|
||||
"rng_game.dll": {}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"libraries": {
|
||||
"rng_game/1.0.0": {
|
||||
"type": "project",
|
||||
"serviceable": false,
|
||||
"sha512": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
BIN
bin/Debug/net8.0/rng_game.dll
Normal file
BIN
bin/Debug/net8.0/rng_game.dll
Normal file
Binary file not shown.
BIN
bin/Debug/net8.0/rng_game.pdb
Normal file
BIN
bin/Debug/net8.0/rng_game.pdb
Normal file
Binary file not shown.
12
bin/Debug/net8.0/rng_game.runtimeconfig.json
Normal file
12
bin/Debug/net8.0/rng_game.runtimeconfig.json
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"runtimeOptions": {
|
||||
"tfm": "net8.0",
|
||||
"framework": {
|
||||
"name": "Microsoft.NETCore.App",
|
||||
"version": "8.0.0"
|
||||
},
|
||||
"configProperties": {
|
||||
"System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,4 @@
|
||||
// <autogenerated />
|
||||
using System;
|
||||
using System.Reflection;
|
||||
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v8.0", FrameworkDisplayName = ".NET 8.0")]
|
||||
BIN
obj/Debug/net8.0/apphost
Executable file
BIN
obj/Debug/net8.0/apphost
Executable file
Binary file not shown.
BIN
obj/Debug/net8.0/ref/rng_game.dll
Normal file
BIN
obj/Debug/net8.0/ref/rng_game.dll
Normal file
Binary file not shown.
BIN
obj/Debug/net8.0/refint/rng_game.dll
Normal file
BIN
obj/Debug/net8.0/refint/rng_game.dll
Normal file
Binary file not shown.
22
obj/Debug/net8.0/rng_game.AssemblyInfo.cs
Normal file
22
obj/Debug/net8.0/rng_game.AssemblyInfo.cs
Normal file
@ -0,0 +1,22 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
using System;
|
||||
using System.Reflection;
|
||||
|
||||
[assembly: System.Reflection.AssemblyCompanyAttribute("rng_game")]
|
||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+dec33453048ca4d891dfd6ead0d30aed725ee33d")]
|
||||
[assembly: System.Reflection.AssemblyProductAttribute("rng_game")]
|
||||
[assembly: System.Reflection.AssemblyTitleAttribute("rng_game")]
|
||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||
|
||||
// Generato dalla classe WriteCodeFragment di MSBuild.
|
||||
|
||||
1
obj/Debug/net8.0/rng_game.AssemblyInfoInputs.cache
Normal file
1
obj/Debug/net8.0/rng_game.AssemblyInfoInputs.cache
Normal file
@ -0,0 +1 @@
|
||||
7396776807f17369622070cdc0741577e0a38bd2e475611b61f14a4b22551e62
|
||||
@ -0,0 +1,13 @@
|
||||
is_global = true
|
||||
build_property.TargetFramework = net8.0
|
||||
build_property.TargetPlatformMinVersion =
|
||||
build_property.UsingMicrosoftNETSdkWeb =
|
||||
build_property.ProjectTypeGuids =
|
||||
build_property.InvariantGlobalization =
|
||||
build_property.PlatformNeutralAssembly =
|
||||
build_property.EnforceExtendedAnalyzerRules =
|
||||
build_property._SupportedPlatformList = Linux,macOS,Windows
|
||||
build_property.RootNamespace = rng_game
|
||||
build_property.ProjectDir = /home/BrainTheBest5/git/rng_game/
|
||||
build_property.EnableComHosting =
|
||||
build_property.EnableGeneratedComInterfaceComImportInterop =
|
||||
8
obj/Debug/net8.0/rng_game.GlobalUsings.g.cs
Normal file
8
obj/Debug/net8.0/rng_game.GlobalUsings.g.cs
Normal file
@ -0,0 +1,8 @@
|
||||
// <auto-generated/>
|
||||
global using global::System;
|
||||
global using global::System.Collections.Generic;
|
||||
global using global::System.IO;
|
||||
global using global::System.Linq;
|
||||
global using global::System.Net.Http;
|
||||
global using global::System.Threading;
|
||||
global using global::System.Threading.Tasks;
|
||||
BIN
obj/Debug/net8.0/rng_game.assets.cache
Normal file
BIN
obj/Debug/net8.0/rng_game.assets.cache
Normal file
Binary file not shown.
1
obj/Debug/net8.0/rng_game.csproj.CoreCompileInputs.cache
Normal file
1
obj/Debug/net8.0/rng_game.csproj.CoreCompileInputs.cache
Normal file
@ -0,0 +1 @@
|
||||
30e81b06136086f3229f17d83fe2d5169ed9003044117fed267fc82bf53f2acb
|
||||
14
obj/Debug/net8.0/rng_game.csproj.FileListAbsolute.txt
Normal file
14
obj/Debug/net8.0/rng_game.csproj.FileListAbsolute.txt
Normal file
@ -0,0 +1,14 @@
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.GeneratedMSBuildEditorConfig.editorconfig
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.AssemblyInfoInputs.cache
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.AssemblyInfo.cs
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.csproj.CoreCompileInputs.cache
|
||||
/home/BrainTheBest5/git/rng_game/bin/Debug/net8.0/rng_game
|
||||
/home/BrainTheBest5/git/rng_game/bin/Debug/net8.0/rng_game.deps.json
|
||||
/home/BrainTheBest5/git/rng_game/bin/Debug/net8.0/rng_game.runtimeconfig.json
|
||||
/home/BrainTheBest5/git/rng_game/bin/Debug/net8.0/rng_game.dll
|
||||
/home/BrainTheBest5/git/rng_game/bin/Debug/net8.0/rng_game.pdb
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.dll
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/refint/rng_game.dll
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.pdb
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/rng_game.genruntimeconfig.cache
|
||||
/home/BrainTheBest5/git/rng_game/obj/Debug/net8.0/ref/rng_game.dll
|
||||
BIN
obj/Debug/net8.0/rng_game.dll
Normal file
BIN
obj/Debug/net8.0/rng_game.dll
Normal file
Binary file not shown.
1
obj/Debug/net8.0/rng_game.genruntimeconfig.cache
Normal file
1
obj/Debug/net8.0/rng_game.genruntimeconfig.cache
Normal file
@ -0,0 +1 @@
|
||||
004b5dc731030bea8726969cd925ed69de83447d2fd5021a445043e049e0310c
|
||||
BIN
obj/Debug/net8.0/rng_game.pdb
Normal file
BIN
obj/Debug/net8.0/rng_game.pdb
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user