I recently came across this:
(int, string) tst = (0, "Test");
The idea behind it seems amazing, before whenever I wanted to map two variables I would use a KeyValuePair. It seems that this is available in .NET Core and not on the regular .NET 4.7.2 which is where I mostly program.
Am I missing something or this is only available on the .NET Core? What is the name of this variable grouping (so I can further research)? Is it the same as creating an object with two variables?
Here is an example:
(int, string) tst = (0, "Test");
var (k, b) = tst;
Console.WriteLine("k: " + k);
Console.WriteLine("b: " + b);
It's a silly question but thank you for the help.