How to store null value to int with C#

1 Answer

0 votes
using System;

class Program
{
    static void Main() {
        int? x = null;
        int? y = 98;

        Console.WriteLine(x);
        Console.WriteLine(y);
    }
}
 
  
  
/*
run:
  

98

*/

 



answered Dec 13, 2020 by avibootz

Related questions

1 answer 113 views
113 views asked Dec 13, 2020 by avibootz
1 answer 172 views
2 answers 223 views
1 answer 205 views
1 answer 109 views
109 views asked Apr 12, 2024 by avibootz
2 answers 244 views
...