Tree data structure in C#

前端 未结 20 2193
梦如初夏
梦如初夏 2020-11-22 08:30

I was looking for a tree or graph data structure in C# but I guess there isn\'t one provided. An Extensive Examination of Data Structures Using C# 2.0 explains a bit about w

20条回答
  •  一生所求
    2020-11-22 09:00

    I am surprised nobody mentioned the possibility to use XML with Linq :

    https://docs.microsoft.com/fr-fr/dotnet/standard/linq/create-xml-trees

    XML is the most mature and flexible solution when it comes to using trees and Linq provides you with all the tools that you need. The configuration of your tree also gets much cleaner and user-friendly as you can simply use an XML file for the initialization.

    If you need to work with objects, you can use XML serialization :

    https://docs.microsoft.com/fr-fr/dotnet/standard/serialization/introducing-xml-serialization

提交回复
热议问题