by tester756 · 1mo ago · 0 comments
Anyway C# has this:
var (_, _, population1960, _, population2010) = QueryPopulationDataForYears("New York City", 1960, 2010);
My original comment was about "the historical inability of commonly used programming languages (from FORTRAN all the way to, say, Java/C#)..." — sure, by the 2010s (when the FP fad got pretty noticeable) the popular programming languages started getting syntactic sugar for handling products/sums, among other things. But in the seventies, the eighties, the nineties, even the early 2000s, the most popular programming languages didn't really have destructuring. Yes, the fringe ones did have it, e.g. Mesa (1979) — in exactly the "list of variables in square brackets" form — but who the hell used them? The mainstream, until very recently, was the single-value assignment only.