2
Answers

NP137 |{2:X}|

Maha

Maha

16y
1.5k
1

Hi Guys

 

NP137 |{2:X}|

 

In this program output is giving 3D326. Please explain the reason.

 

Thank you

 

using System;

 

public class MainClass

{

    public static void Main()

    {

        int i = 250662;

 

        string s = string.Format("|{0,10:X}|{1,10}|{2:X}|{3}|", i, i, i, i);

 

        Console.WriteLine(s);

    }

}

//|     3D326|    250662|3D326|250662|

Answers (2)