设为首页  
联系我们  
加入收藏  
网页制作 冲浪宝典 图形图像 操作系统 软件教学 编程开发 认证考试 安全技术 站长专区 文学驿站 娱乐天地 游戏天地 办公软件
文章搜索
您的位置: 首页 >> 文章首页 >> 编程开发 >> 其他开发语言 >> 面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇
精品推荐
其他开发语言点击TOP10
·数字小键盘指法练习
·用C语言编通讯录程序(初学者级别的)
·Modem 常用AT指令集
·单片机模拟I2C总线及24C02(I2C EEPROM)读写实例(源代码)
·C++经典电子书下载
·Thinking in C++ 简体中文第二版
·debug和release的区别
·error LNK2001: unresolved external symbol __ftol2 错误解决
·C库函数手册
·一个简单的C语言编译器
编程开发点击TOP10
·数字小键盘指法练习
·ASP.NET 程序中常用的三十三种代码
·用C语言编通讯录程序(初学者级别的)
·我写的Java学生成绩管理系统源代码
·CHK文件恢复工具
·Modem 常用AT指令集
·java笔试题
·异常java.sql.SQLException: Io exception:The Network Adapter could not establish connection
·单片机模拟I2C总线及24C02(I2C EEPROM)读写实例(源代码)
·C++经典电子书下载
精选专题

面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇

作者: 来源:网络文章 时间:2005-12-17 19:14:25

面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(5) where [] denote integral part of the log base 2 of n

Example
So if we want 0 to 15 dollars
[log of 15 to base 2] + 1 = [3.90] + 1 = 3 + 1 = 4 boxes
we need to have 4 boxes each having 1,2,4,8, dollars respectively.Now we know from binary numbers that any amount from 0 to 15 can be formed with this boxes.

For 0 to 6 dollars
[log of 7 to base 2] + 1 = [2.58] + 1 = 2 + 1 = 3 boxes
we need to have 3 boxes each having 1,2,4, dollars respectively

For 0 to 100 dollars
[log of 100 to base 2] + 1 = [6.64] + 1 = 6 + 1 = 7 boxes
we need to have 7 boxes each having 1,2,4,8,16,32,64 dollars respectively

-Ameya Vaidya

7What is the sum of the numbers from 1 to 1000?

Depends what NUMBER means here:

If means integer, that's 100*(100+1)/2=5050;
If not, that's infinity.

8You are an employer. You have ten employees. Each month, each one of your ten employees gives you ten bags of gold. Each bag of gold has ten pieces of gold in it. Each piece of gold weighs one pound. One of your employees is cheating you by only putting nine pieces of gold in each of his ten bags of gold. You have a scale (not a balance, a scale), and you can only take one measurement from the scale, only one (1) reading. How can you tell which of the ten employees is cheating you by using this scale and only taking one measurement?

---When your employees come to pay you at the end of the month, take one bag from employee number one's pile and set it aside. Take two bags from employee number two's pile and add it to the one from employee number one. Take three from employee three, four from employee four, etc...

Once you have now compiled a pile of bags, you should have 55 bags (one from one, two from two, etc). Set the whole pile (all 55 bags) on the scale and take a reading. If all the bags were honest, you would have 550 pounds on the scale.

If employee one is cheating you, then the reading would be 549, since you only have one bag from employee one. Likewise, if the measurement is 547, then 3 pounds are missing, and employee three is the thief.

--- I think we are given a scale not a balance. So we can’t tell the exact weight of the bags. So how do we find out whether its 549, 547 etc.?

--- Why does he need to weigh? Can't he just count?

9How many points are there on the globe where by walking one mile south, one mile east and one mile north you reach the place where you started.

--At the North Pole, The South Pole wouldn't quite work, since you can only go north from the South Pole.

--Both answers (North Pole, and all points on the circle 1 mile north of the circle having circumference of 1 mile around the South Pole) are right.

10How would go about finding out where to look for a book in a library? (You do not know how the books are organized beforehand)

-- I would go and ask a person in charge of arranging the books instead of wasting my time in searching all of them

-- This question is open ended , though Microsoft might be testing fundamentals on Binary search , Indexing etc by asking this.

The approach I would take is , check out the index cards and find the shelf where the book is located. Then do an alphabetical search by physically going to that shelf. You can also say that you would start on the top of the shelf or the bottom depending on the "letter" name of the book etc.

-- I would leave the library, drive to the exact location of the person who wrote this question, and slap them.

11Imagine you are standing in front of a mirror, facing it. Raise your left hand. Raise your right hand. Look at your reflection. When you raise your left hand your reflection raises what appears to be his right hand. But when you tilt your head up, your reflection does too, and does not appear to tilt his/her head down. Why is it that the mirror appears to reverse left and right, but not up and down?

-- It's mainly because man himself is "left-right" symetric but not "up-down" symetric.

-- This is not a Physics issue... this is a matter of perception.

When you stand in front of the mirror and raise YOUR LEFT HAND, the reflection is of YOUR LEFT HAND.

By referring to "what appears to be his right hand" the question has essentially asked you to envision yourself rotated 180 degrees about a vertical axis, thus subtly introdUCing the apparent conflict between left and right.

Why it works: Since humans are relatively symmetric along a vertical axis you are able to envision YOUR LEFT HAND as a suitable RIGHT HAND for your reflection.

Humans are not generally symmetric along a horizontal axis (hey, I've never seen it, but that doesn't mean some freak isn't out there...), so it's much harder to envision feet as a suitable head and vice versa.

12You have a bucket of jelly beans. Some are red, some are blue, and some green. With your eyes closed, pick out 2 of a like color. How many do you have to grab to be sure you have 2 of the same?

If you select 4 Jelly beans you are guaranteed that you will have 2 that are the same color.

13You are given a scale which you are to use to measure eight balls. Seven of these balls have the same weight: the eight ball is heavier than the rest. What is the minimum number of weighs you could perform to find the heaviest of the eight balls?. Remember it's a scale not a balance. (i.e. It can just tell you if one side is heavier than the other it can't give you the exact weight).

!..Umm. You can do this in 2 weighs. Put three balls on each side of the scale. That's a total of six balls you're weighing. If the three balls on each side weigh equally, you know that one of the two remaining balls is the heaviest. Weigh those two balls to determine which one is heaviest. If, however, one of the three ball combinations weighs most, remove all balls from the scale, then weigh just two of the three "heavier" balls. If those two balls are equal weight, the third, unweighed ball is the heaviest; otherwise the scale will indicate which of the two balls on the scale is the heavier one.

So, what’s the difference between a balance and a scale?

14How would you design a toaster?

1. Find out Voltage to be supported

1.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(1)
2.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(2)
3.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(3)
4.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(4)
5.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(5)
6.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(6)
7.面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇(7)
共7页 9 7 [1] [2] [3] [4] [5] [6] [78 :>

面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇 相关文章:
面试时最经常被问到的问题(Frenquently asked interview questions)之Analytical, puzzles, and brain-teasers篇 相关软件:
特别声明:本站除部分特别声明禁止转载的专稿外的其他文章可以自由转载,但请务必注明出处和原始作者。文章版权归文章原始作者所有。对于被本站转载文章的个人和网站,我们表示深深的谢意。如果本站转载的文章有版权问题请联系编辑人员,我们尽快予以更正。
转载请注明来源:http://www.xgdown.com