? syntax [Answered]
public void Add(T newItem)
{
var insertAt = _Inner.Count == 0 ? 0 : new Random().Next(0,_Inner.Count+1);
_Inner.Insert(insertAt, newItem);
}
What does the ? mean in this code?
{
var insertAt = _Inner.Count == 0 ? 0 : new Random().Next(0,_Inner.Count+1);
_Inner.Insert(insertAt, newItem);
}
What does the ? mean in this code?