-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProgram.cs
More file actions
47 lines (42 loc) · 1.49 KB
/
Copy pathProgram.cs
File metadata and controls
47 lines (42 loc) · 1.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
using System;
using System.Collections.Generic;
using System.Linq;
using FamilyGenerator.Enums;
using FamilyGenerator.ExtensionMethods;
using FamilyGenerator.Models;
namespace FamilyGenerator
{
class Program
{
static void Main(string[] args)
{
DateTime date = new DateTime(1345, 1, 1);
List<City> baseCities = new List<City>()
{
new City("Firenze"),
new City("Genova"),
new City("Mantua"),
new City("Milano"),
new City("Siena"),
new City("Venezia")
};
// do for each of the cities
foreach (City city in baseCities)
{
// create ten FAMILIES
for (int i = 0; i < 10; i++)
{
Family family = new Family(FamilyTypeEnum.Human);
family.CreateFamily(date, city, 18, true); // create family
// for each of the random family members
foreach (FamilyMember member in family.FamilyMembers)
{
Console.Write($"{member.Name} {member.Age} ({member.Type.ToDescription()}, {member.LifestyleTraits.First().ToDescription()}), "); // tell name and age and type
}
Console.WriteLine();
Console.WriteLine();
}
}
}
}
}