本文介绍了字符串到字节数组的转换的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何将字符串(代表十进制值)转换为字节数组?


假设用户输入1000,程序将生成{E8,03,00,00}

1000000将给出{40,42,0F,00}



是否有执行此功能的功能?我记得我以前见过类似的东西,但我不记得在哪里.也许我在做白日梦.

无论如何,谢谢预先感谢您的评论和帮助...

How do you convert from a string (that represents a decimal value) to a byte array?


Let says the users enter 1000 the program would produce {E8, 03, 00, 00}

And 1000000 will give {40, 42, 0F, 00}



Is there a function that does this? I remember that I saw something like this before but I can not remember where. Maybe I was day dreaming.

Anyway, thanks In advance thanks for the comments and help...

推荐答案




这篇关于字符串到字节数组的转换的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-29 15:50
查看更多