For The Following C Code Select The Relevant Solution For #67
For the following C# code select the relevant solution for conversion of data type.</p> <pre><code class="language-csharp" line="1"> static void Main(string[] args) { int num1 = 20000; int num2 = 50000; long total; total = num1 + num2; Console.WriteLine("Total is : " +total); Console.ReadLine(); } </code></pre>
This multiple choice question (MCQ) is related to the book/course gs gs108 CSharp. It can also be found in gs gs108 Data Types, Variables and Operators - Type Conversion in Expressions - Quiz No.1.
For the following C# code select the relevant solution for conversion of data type.
static void Main(string[] args) { int num1 = 20000; int num2 = 50000; long total; total = num1 + num2; Console.WriteLine("Total is : " +total); Console.ReadLine(); }
Compiler will generate runtime error
Conversion is implicit type, no error generation
Specifying data type for conversion externally will solve the problem
None of the mentioned