C#, you can make a parameter optional by specifying a default value for that parameter in the method signature.
the optionalParam parameter has a default value of 0, so it's optional. If you call MyMethod without providing a value for optionalParam, it will default to 0. If you provide a value for optionalParam, it will use the provided value instead of the default value. The requiredParam parameter does not have a default value, so it must always be provided when calling MyMethod.