using System;
using System.Collections.Generic;
namespace project
{
class Program
{
static int Find()
{
return 0;
}
class Monster
{
public int Id { get; set; }
}
static void Main(string[] args)
{
// Nullable -> Null + able
int? number = null;
int c = (number != null) ? number.Value : 0;
int b = number ?? 0;
System.Console.WriteLine(b);
Monster monster = null;
if (monster != null)
{
int monsterId = monster.Id;
}
int? id = monster?.Id;
if (monster == null)
{
id = null;
}
else
{
id = monster.Id;
}
}
}
}