Skip to content

Instantly share code, notes, and snippets.

@tejpaldev
Last active March 22, 2022 11:19
Show Gist options
  • Save tejpaldev/668caa3b5b37f384bbeff51d958dd0e2 to your computer and use it in GitHub Desktop.
Save tejpaldev/668caa3b5b37f384bbeff51d958dd0e2 to your computer and use it in GitHub Desktop.
int y = Nullable.Compare<DateTime>(DateTime.UtcNow, x);
if y=-1 means x is greater
if y=1 means x is lesser
if y=0 means equal
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment