What Will Be The Output Of The Following C Code Snippetp Pre #847
What will be the output of the following C# code snippet?</p> <pre><code class="language-csharp" line="1"> class UnsafeCode { unsafe static void Main() { char[] arr = { 'A', 'B', 'C', 'D', 'E' }; fixed (char* P = arr) { int i; for (i = 0 ;i < 5 ;i++) if (*P % 2 == 0) ++*P; else (*P)++; Console.WriteLine(arr); } 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 Miscellaneous Topics - Pointers Operation - Quiz No.1.