prepare

amazon:

DP

design


1. A class B network on the internet has a subnet mask of 255.255.240.0, what is the maximum number of hosts per subnet .

  a. 240 b. 255 c. 4094 d. 65534

  2. What is the difference: between o(log n) and o(log n^2), where both logarithems have base 2 .

  a. o(log n^2) is bigger b. o(log n) is bigger

  c. no difference

  3. For a class what would happen if we call a class’s constructor from with the same class’s constructor .

  a. compilation error b. linking error c. stack overflow d. none of the above

  4. “new” in c++ is a: .

  a. library function like malloc in c

  b. key word c. operator

  d. none of the above

  5. Which of the following information is not contained in an inode .

  a. file owner b. file size

  c. file name d. disk address

  6. What’s the number of comparisons in the worst case to merge two sorted lists containing n elements each .

  a. 2n b.2n-1 c.2n+1 d.2n-2

  7. Time complexity of n algorithm T(n), where n is the input size ,is T(n)=T(n-1)+1/n if n>1 otherwise 1 the order of this algorithm is .

  a. log (n) b. n c. n^2 d. n^n

  8. The number of 1’s in the binary representation of 3*4096+ 15*256+5*16+3 are .

  a. 8 b. 9 c. 10 d. 12


设计贪吃蛇的游戏,问问贪吃蛇的数据保存形式(是数组还是链接表)

字符串逆置


一个是so easy 排序的,不说了,还有一个是智力题目,就是依次有三个空杯,三个满杯,然后只能动一个杯子,使这些杯子变成满的空的间隔排放

分布式系统的基础——选举算法,没有zookeeper可以用的时候,自己会写一个对付对付么? 
搜索引擎的基础——反向索引、jump list、索引压缩,知道了以后至少能看懂Xapian或者Elasticsearch在干什么 
星际二以及XBox天梯的玩家匹配算法——TrueSkill,其实原理不复杂,平常自己公司的乒乓球赛用的就是这个算法的简单实现 

其实只要数据量稍微大一点,性能有瓶颈了,想着优化了,对你的算法基础知识的考验就来了。

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符  | 博主筛选后可见
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值