![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
笔试、面试
Joogle
这个作者很懒,什么都没留下…
展开
-
2013星网锐捷笔试题
啤酒一块钱一瓶,两个空瓶可以换一瓶啤酒,一个人有n元钱,问这个人可以喝到多少瓶啤酒?要求用递归实现。1.非递归int total(int n){ int battl = 0; int empty = 0; while (n > 0) { --n; ++battl; if (++empty == 3) { empty = 0;原创 2012-10-23 18:38:50 · 4773 阅读 · 2 评论 -
2013卫士通校园招聘
将十进制整数转换为十六进制字符串1.法一void itohex(int n, char* str){ char tab[] = "0123456789ABCDEF"; char tmp[8]; int i = 0, j = 2; str[0] = '0'; str[1] = 'x'; do { tmp[i++] = tab[n%16]; n原创 2012-11-01 11:07:18 · 1549 阅读 · 0 评论