1

Visual Studio is showing two things for boolean type like:

Boolean and bool

And for double type:

Double , double

Why so? Two are in different colors and will they both are same? What is the difference?

James Donnelly
  • 117,312
  • 30
  • 193
  • 198
Seema
  • 67
  • 1
  • 6
  • 2
    they are the same. only that `bool` is an alias of `Boolean`. [See here.](http://stackoverflow.com/a/215422/491243) – John Woo Oct 25 '13 at 07:38

2 Answers2

2

They are the same. If you mouse over the lowercase one it shows that it is an alias to the uppercase version.

Note that by convention you should always use the lowercase version

mgttlinger
  • 1,375
  • 1
  • 20
  • 34
2

bool is an alias for System.Boolean, where as double is an alias for System.Double and int is an alias for System.Int32

They are all essentially the same.

Henk Jansen
  • 1,092
  • 8
  • 26