Resolved: C# “generic value parameters”

In this post, we will see how to resolve C# “generic value parameters”

Question:

Is there such a thing as “generic value parameters” to set specific values in the variable declaration instead of in the constructor? Look at this Example: I want to use something like this:
instead of this:

Best Answer:

Like it or not, you’re expected to use a field, which you can require in the constructor. Generics are only for types.

If you have better answer, please add a comment about this, thank you!

Source: Stackoverflow.com