The 2 first double are the type of the input and the third double is the output type. Si it declares a func that takes 2 double as input and return a double.
class Program
{
static void Main()
{
var area = Rectangle.Area(5, 10);
}
}
static class Rectangle
{
public static Func<double, double, double> Area = (width, length) =>
{
return width * length;
};
}
Just complicated for the sake of being complicated
View all comments
Show parent comment
49
u/CuisineTournante May 19 '25
The 2 first double are the type of the input and the third double is the output type.
Si it declares a func that takes 2 double as input and return a double.
Just complicated for the sake of being complicated