Hello everyone!
I'm a newbie self thought wanna be programmer, I have recently been looking through someone else's c# code I found online, and found something I haven't really seen before could someone explain me what question mark after the type does in this Constructor?
I know what double exclamation mark (??) does or single exclamation mark with variable declaration e.g. (int?) but the above is something new, I had a quick look around msdn but it doesn't explain much in regard to it.
Thank you for help!
I'm a newbie self thought wanna be programmer, I have recently been looking through someone else's c# code I found online, and found something I haven't really seen before could someone explain me what question mark after the type does in this Constructor?
C#:
public Inventory this[int index]
{
get
{
return _inventories?[index];
}
set
{
_inventories[index] = value;
OnCollectionChanged(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Replace, _inventories[index]));
}
}
I know what double exclamation mark (??) does or single exclamation mark with variable declaration e.g. (int?) but the above is something new, I had a quick look around msdn but it doesn't explain much in regard to it.
Thank you for help!