Skip to content

Application that answers relation queries given some pre-existing relationships.

Notifications You must be signed in to change notification settings

jittrfunc/FamilyTree

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Family Tree

This is a console application that processes parent-child and spouse relationships between individuals and answers additional queries that can be derived from those relationships.

The application takes a text file as input which specifies the relationships and queries and after processing the relationships outputs the results / answers to the console.

Sample input file location ./SampleInput

Functions supported in the input file

  • ADD_SPOUSE <husband's name> <wife's name>

  • ADD_CHILD <mother's name> <child's name> <child's gender>

  • GET_RELATIONSHIP <person's name> <relationship to find>

Supported gender values Male | Female

Supported relationship values Paternal-Uncle | Maternal-Uncle | Paternal-Aunt | Maternal-Aunt | Brother-in-Law | Sister-in-Law | Siblings | Son | Daughter

Directions to run

  • Install dotnet core v3.1 or later (if not already present)
  • cd to the root folder for the application (containing the FamilyTree.sln file)
  • Run dotnet build -o dist
  • Run using an input file dotnet dist/FamilyTree.dll ".\SampleInput\input1.txt"

Directions to test

  • Install dotnet core v3.1 or later (if not already present)
  • cd to the root folder for the application (containing the FamilyTree.sln file)
  • Run dotnet test

About

Application that answers relation queries given some pre-existing relationships.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages