Illustrated C#2012 by Daniel Solis

Safari, the world’s most comprehensive technology and business learning platform.

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required

O'Reilly logo

C H A P T E R  16

Conversions

What Are Conversions?

To get an understanding of what conversions are, let's start by considering the simple case in which you declare two variables of different types and then assign the value of one (the source) to the other (the target). Before the assignment can occur, the source value must be converted to a value of the target type. Figure 16-1 illustrates type conversion.

  • Conversion is the process of taking a value of one type and using it as the equivalent value of another ...

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required