❔ Getting property from object based on input
Is it possible to create a function that would look something like this? Here I already have the object and I know for sure that the property actually exists. I'm quite new to C#, so I don't know if this is actually possible