【发布时间】:2020-07-01 08:00:08
【问题描述】:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace CLASSES_2
{
class Building
{
public int Area; // total square footage of building
public int Floors; // number of floors
public int Occupants; // number of occupants
}
class Building_Demo
{
static void main(string[] args)
{
Building house = new Building();
int Area_Per_Person;
house.Area = 4000;
house.Floors = 7;
house.Occupants = 10;
Area_Per_Person = house.Area / house.Occupants;
Console.WriteLine("The house has: \n" + house.Floors + " Floors \n" + house.Occupants + " Occupants"
+ house.Area + "Area \n" + Area_Per_Person + " Area_Per_Person: ");
}
}
}
谁能告诉我我的代码有什么问题?它告诉我没有适合入口点的方法。
CS5001 程序不包含适用于入口点的静态“Main”方法。
【问题讨论】: