2016-04-06から1日間の記事一覧

【C#】constとstatic readonlyの違いと使い分け

C#

C#でプログラム書いてるとコードを書いているときは、constとreadonlyの区別ってあんまりありませんよね。ついつい定数は、constと書いてしまいます。 public static class HogeDefine { public const uint MaxLength = 10; public static readonly uint Dat…