Series is doing well. Might be worth doing a follow up on the use cases for the different types Enumerable, Array, List, Dictionary etc. What they are good at and and when they are slow. Diction lookup vs array scan etc
RE: C# Tutorial 006: Lists & Arrays
You are viewing a single comment's thread from:
C# Tutorial 006: Lists & Arrays
Thanks for the feedback! I was personally thinking to first teach a bunch of the basics before moving on to Enumerable and Dictionary,
I'm also not really a big fan of using Dictionary after I ran into some trouble with it when developing a game on Unity.
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
What was the problem you had with Dictionary?
I use them a fair deal in my code but do not tend to pass them around. I prefer to pass their lookup function around. So if I have a Dictionary<int, Person> I will pass around a Func<int, Person>
That way I do not care what the storage is :)
Unity is a different space as threaded, the C# collections are not thread safe
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
The XmlSerializer I had to use could not serialize Dictionaries. At first I had a workaround, but it just became too much of a struggle with several dictionaries so I had to switch To Lists or Arrays.
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Btw, check out my posts. I have a series on pushing C# outside the OO norms
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit