题目及答案参考:地址

为什么腾讯笔试的时间是10:30到12:30?难道腾讯人事部认为计算机的学生都是3点睡觉,9点起床,13点吃饭的吗?做了半个小时的题,就饿了;而且刚开始发卷子的时候,那卷子的模样,我是有多么熟悉啊:长长的,白白的,分明就是当年血战的高考卷子模样啊,一瞬间心血沸腾。拿到卷子后,就有点晕了,我是真的在编程啊,可是我怎么对题目就不知道如何下手呢?感觉题目就像是这样的:我们每天都在吃饭,然后问我们当拿筷子的时候,手握在离筷子尾部多长的位置?此时此刻,我真想找双筷子来我一下,谁吃饭的时候会思考会留意这个问题呢?我饿了,我要吃饭,我为什么要考虑吃饭的超级细节东西?我写程序,写程序只是个工具,我需要我的数据结果就ok了,我为什么要考虑一个无符号字符变量转换成有符号字符变量时候是什么模样?我突然意识到了我平常的训练目的和腾讯的考试目的差异是有多么的大:我是以解决问题为目的而使用工具,腾讯希望找到的是一个会熟练使用工具的能工巧匠。很遗憾的是我不是一个能工巧匠,在此向腾讯的码畜,码农,码工,码管等各级码人致敬!

言归正传,每次考试都要有所收获,都要吸取教训,我这次考试如同前几次考试一样,深深地意识到了本科不是计算机专业的各项劣势,要知道在一个和计算机沾一点点边的数学系泡四年,和在计算机专业泡四年,差别还是很大的。操作系统方面是我严重的缺陷,数据类型转换也很无语。这次投的是测试开发工程师,我压根都不知道这是干嘛的。。。很囧

1 基本数据类型转换

1)解决有符号和无符号的问题。 对于字符类型和整型来说, Assuming the size of type is k, if one unsigned data type a  is converted to the signed one b ,when a is larger than 2^(k-1), b is equal to a-2^(k)+1; otherwise, b is equal to a. If one signed data type b is converted to the unsigned one a,  when b is less than 0, a is equal to b+2^k. We have to understand that the changing of "signed" aims to  change the range of number presented by the k bits, but also maintain the same meaning as much as possible. Generally, the highest bit is the signal, if this highest bit is explained  as unsignal, so the range of number can be expanded. Noted that when the changing of "signed" happened, the explaination of meaning is changed , but the real bits do not change.

2) 类型转换。if there are converation between two different data types having different size, we have to handle the transfomation. First, if we converted a long data type to a short data type, we truncate the long data bits based on the size of short data type. Assuming we have to truncate1 Bytes from the 4 Bytes(0xff fe  fd  f7), which Bytes do we obtain? the left ,the most right? or the other.  This is decided by the big-endain storage or the little-endain storage. If it is the former, we get ff; If it is the latter, we get f7. Second, if we convert a short data type to a long data type, it is not as easy as filling enough 0 to the vacancy bits. For instance,  convertation from char to int, the most improtant thing is keeping the value unchanged. For any positive value of char type, we fill 24 0. For any negtive value of char type, we filee 24 1. For instance , 1111 1100=-4, the int is 0xff ff ff fc(1111 1100)  . If we convert one int to ont float , There is some complex operation to finish.

All the above conversions are kind of standard conversion, there is still another conversion:forced conversion. there is no complement, no add 1. Baed on the changing of  point, the machine just explain the real bits in the memary, and do not change bits.

2  About the parameters of functions. const parameter

3 For a point a ,a++ is rather different with a=a+1

4 sizeof(long long) is 8. I do not even know this kind of spelling!  but in the function of "printf", the format is %d, so for every parameter, it only read 4 Bytes every time, then we can find the real resluts .Note that it is little-endian storage.

5 operation system   : kernel mode and user mode: the kernel mode has the highest priority, and does some operation such as resource allocation, computing adn so on. the user mode mainly lies on the cache. Some approaches from the suer mode to the kernel mode: 1)system calling (like applying a new process);2)interruption of peripherals(finishing the reading disks);3) some specific conversion operation(search information following the describer, keep the current information, keep them in regesters) open function belonging to system calling can open device files, fopen belonging to the standard C library can open general files.

6 some algorithms about memary management. Lru least recently used

7 DMA 在实现DMA传输时,是由DMA控制器直接掌管总线,因此,存在着一个总线控制权转移问题。即DMA传输前,CPU要把总线控制权交给DMA控制器,而在结束DMA传输后,DMA控制器应立即把总线控制权再交回给CPU。

8 I am not familar about the concepts of trees,  what a pity.

keep studying ,

Thanks my friend XinXin Zhang, who helps me fighure out most of the above mentioned thing patiently.

Sometimes I feel discussion contributes to keep things in mind and long time. After discussion , we conclude it and check them in the book c++ primer.

转载于:https://www.cnblogs.com/18fanna/archive/2013/04/16/3022005.html

3013-04-13 腾讯笔试相关推荐

  1. 腾讯笔试面试经历(2010年)

    发信人: sysuzsx (sysuzsx), 信区: MC 标 题: 腾讯笔试面试经历 发信站: 逸仙时空 Yat-Sen Channel (Mon May 24 13:01:43 2010) 今天 ...

  2. 2011年9月 成都 腾讯笔试 面试过程(亲身体验,仅供参考娱乐)(一)

    写这篇日志居然已经是时隔三年了,还依稀记得刚上大学那会儿...时间飞逝啊,感慨万千. 不是神马教程类文章,也不具有代表性,仅作为自己记录找工作过程的点滴. 腾讯笔试+第一次面试 24日上午10点到12 ...

  3. Ubuntu 14.04 / 13.10 / 13.04 / 12.04使用PPA安装NVIDIA GeForce显卡驱动

    最近,在一台比较老的PC上装了ubuntu 14.04,安装过程中时不时花屏,开机输入密码后直接花屏卡死,最后google确认是ubuntu的开源驱动,对较老的NVIDIA显卡驱动有问题.so,看到一 ...

  4. dp - 2016腾讯笔试 A

    2016腾讯笔试 A Problem's Link -------------------------------------------------------------------------- ...

  5. 2020-08-23腾讯笔试 删除节点 数字拆分

    腾讯笔试 [题目1]删除节点 给出一个单链表,删除一个节点,输出删除后的所有节点的值 输入两行. 第一行n,k,表示原链表长度n,要删除第k个节点. 第二行n个整数表示原链表每个节点的值. [代码]1 ...

  6. 2015腾讯笔试大题

    今天做完腾讯的在线笔试,感觉自己弱爆了,选择题部分考得比较基础,但是考的面比较广,数据结构,计算机网络,算法常识,概率题,C,C++,都有.大题如下: 在一组数的编码中,若任意两个相邻的代码只有一位二 ...

  7. 2013腾讯笔试之旅

    今天是个好日子,艳阳高照,值得出门.今天也是个比较特殊的日子,因为要去做个实习生笔试,而且还是腾讯这家猎头.对于我们这种名不见经传的二本学校来说,能给个笔试的机会就算不错了,哪里像某某科技大学,人才是 ...

  8. 腾讯笔试、OMG一面、二面、HR面

    一年有余没有写博客了,这一年经历了很多事.找实习.夏令营.考研.脚骨折受伤.复试.来到中科院工作.直到最近,才有时间一一记录这一年以来的发生的种种事情.先从去年腾讯面试说起吧,时间久远,可能记忆得不是 ...

  9. 百度+阿里+腾讯+笔试题目(2020届)

    百度度秘事业部 百度是我第一家面试的公司,而且还是bat的大厂级别,那时的我也不知道自己啥水平,接到面试电话慌的不行,面试第一次非常难忘.下午3点,面试40分钟! 百度一面: 1.实验室项目里面使用什 ...

最新文章

  1. 图像也能做情感迁移?罗切斯特大学团队提出计算机视觉新任务
  2. (筆記) 如何在字串中從指定字元抓到指定字元(pointer版)?
  3. 文本框输入怎么样让键盘消失
  4. POI(java 操作excel,word等)编程
  5. 如何把Win11任务栏变窄
  6. mac下配置进行c和matlab混编
  7. ICCV 2019 | 华科提出对称性约束的校正网络ScRN,显著改进场景文本识别
  8. 西部数码虚拟服务器备案,虚拟主机备案才能使用吗
  9. 网络驱动器映射成功但无法实时更新文件需要重新连接_无边界办公——WebDAV文件共享服务构建...
  10. 怎么编译shell_运维如何才能学好 Shell?
  11. python——item()返回可遍历的(键,值)元组数据
  12. 第43条:掌握GCD及操作队列的使用时机
  13. 定制问卷|表单收集系统-对接特殊接口(表单系统)
  14. 小灰的算法之旅python篇pdf_漫画算法 小灰的算法之旅 Python篇
  15. 计算机丢失vcomp110.dll,msvcp110.dll丢失一键修复工具
  16. 数据拟合丨人口预测模型
  17. 【OpenGL】斯坦福兔子、显示列表
  18. Go语言Revel框架 环境搭建
  19. 动态MAC地址和静态MAC地址
  20. 钉钉群机器人关键词自动回复_wetool自动接受新好友wetool pc版-客服

热门文章

  1. 征信逾期花钱就能修复?小心跳进骗子的坑里面去
  2. 为什么销售员贷款比较难?
  3. Ubuntu 18.04 LTS环境下 MNN 的编译与使用
  4. 微型嵌入式操作系统对比
  5. 腾讯云,物联网通信产品,动态注册步骤
  6. 服务器系统wlanapi,没有找到wlanapi.dll怎么办?
  7. java8 list 行转列_Java14 都来了,你还不会用 Java8吗?
  8. 猫咪藏在哪个房间python作业_python练习题之 猫2
  9. Postman status: 415_415亩!白云首宗农村土地规模化流转成功签约
  10. 10分钟看懂浏览器的渲染过程及优化