What is the output of below? 1? 3? 5? 6?\
int? x = null;
int val = 1 + x ?? 2 + 3;
Console.WriteLine(val);
Answer:
5
Explanation:
- Arithmetic operators have higher precedence
- 1 + null == null
What is the output of below? 1? 3? 5? 6?\
int? x = null;
int val = 1 + x ?? 2 + 3;
Console.WriteLine(val);
Answer:
5
Explanation: