This commit is contained in:
La Programmatrice Verde 2025-04-04 10:01:25 +02:00
parent 2491ea45d2
commit be7f5aebc7
9 changed files with 82 additions and 8 deletions

26
Auto.cs Normal file
View File

@ -0,0 +1,26 @@
namespace oggetti_1;
class Auto {
readonly int cilindrata;
readonly string targa;
readonly double peso;
readonly double volume;
readonly string marca;
public Auto(int p_cilindrata, string p_targa, double p_peso, double p_volume, string p_marca) {
this.cilindrata = p_cilindrata;
this.targa = p_targa;
this.peso = p_peso;
this.volume = p_volume;
this.marca = p_marca;
}
public void Stampa() {
Console.WriteLine($"Cilindrata: {this.cilindrata}");
Console.WriteLine($"Targa: {this.targa}");
Console.WriteLine($"Peso: {this.peso}");
Console.WriteLine($"Volume: {this.volume}");
Console.WriteLine($"Marca: {this.marca}");
}
}

View File

@ -1,5 +0,0 @@
namespace oggetti_1;
class Grafica {
}

View File

@ -2,8 +2,11 @@
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello, World!");
static void Main(string[] args) {
Auto auto = new Auto(3600, "DV643RH", 2547.3, 8472, "Ford");
Auto auto2 = new Auto(2400, "AB482GT", 2345.542, 4325, "FIAT");
auto.Stampa();
auto2.Stampa();
}
}

View File

@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v9.0", FrameworkDisplayName = ".NET 9.0")]

View 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("oggetti_1")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+2491ea45d236ee677dca113d65a3cbfa7f42fa4a")]
[assembly: System.Reflection.AssemblyProductAttribute("oggetti_1")]
[assembly: System.Reflection.AssemblyTitleAttribute("oggetti_1")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// Generated by the MSBuild WriteCodeFragment class.

View File

@ -0,0 +1 @@
4733b9c6edd51ecb0171ae4b6be6f468f05027dc26b187ba771da8d0a6e7486f

View File

@ -0,0 +1,15 @@
is_global = true
build_property.TargetFramework = net9.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 = oggetti_1
build_property.ProjectDir = /home/Verde/git/oggetti_1/
build_property.EnableComHosting =
build_property.EnableGeneratedComInterfaceComImportInterop =
build_property.EffectiveAnalysisLevelStyle = 9.0
build_property.EnableCodeStyleSeverity =

View 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;

Binary file not shown.