緣起:
在 Ubuntu 上安裝 .NET Core SDK,並成功建立 Console
專案後,我下一步想試的是,建立 Web 專案
官方教學,我先 cd 到放我 C# 專案的資料㚒,然後下指令來建立專案
dotnet new webapp -n AspNetCoreDemo -o firstwebapp
dotnet new webapp -n AspNetCoreDemo -o firstwebapp
internal class Program
{
class Performance
{
public int SN { get; set; }
public string Name { get; set; }
public Performance(int sN, string name)
{
SN = sN;
Name = name;
}
public override string ToString()
{
return $"SN:{SN}, Name:{Name}";
}
}
class Review
{
public int PerformanceSN { get; set; }
public string Name { get; set; }
public bool IsPass { get; set; }
public Review(int performanceSN, string name, bool isPass)
{
PerformanceSN = performanceSN;
Name = name;
IsPass = isPass;
}
public override string ToString()
{
return $"PerformanceSN:{PerformanceSN}, Name:{Name}, IsPass:{IsPass}";
}
}
}