【发布时间】:2014-03-25 09:56:04
【问题描述】:
如何将十进制数转换为一个字节格式的十六进制数。
e.g if decimal = 15 , Output = 0x0F and Not 0xF ,
if decimal = 240 , Output = 0xF0
Console.WriteLine("{0:x}", i) solutions gives 0xF not 0x0F.
在 C# 中有 ToINt16/32/64 但没有 ToINt8?
【问题讨论】: