微软2013暑假实习生笔试题

原创 2013年04月06日 20:20:53

部分题目答案不确定,会持续更新……

1. Which of the following calling convention(s) support(s) supportvariable-length parameter(e.g. printf)?(3 Points)

    A. cdecl    

    B. stdcall    

    C. pascal    

    D. fastcall

2. What's the output of the following code?(3 Points)

class A
{
public:
    virtual void f()
    {
        cout<<"A::f()"<<endl;
    }
    void f() const
    {
        cout<<"A::f() const"<<endl;
    }
};

class B: public A
{
public:
    void f()
    {
        cout<<"B::f()"<<endl;
    }
    void f() const
    {
        cout<<"B::f() const"<<endl;
    }
};

void g(const A* a)
{
    a->f();
}

int main()
{
    A* a = new B();
    a->f();
    g(a);
    delete a ;
}

    A. B::f()B::f()const    

    B. B::f()A::f()const   

    C. A::f()B::f()const    

    D. A::f()A::f()const 

3. What is the difference between a linked list and an array?(3 Points)

    A. Search complexity when both are sorted

    B. Dynamically add/remove

    C. Random access efficiency

    D. Data storage type

【此题D选项存在疑问】

4. About the Thread and Process in Windows, which description(s) is(are) correct:(3 Points)

    A. One application in OS must have one Process, but not a necessary to have one Thread

    B. The Process could have its own Stack but the thread only could share the Stack of its parent Process

    C. Thread must belongs to a Process

    D. Thread could change its belonging Process

5. What is the output of the following code?(3 Points)

{
  int x = 10 ;
  int y = 10 ;
  x = x++ ;
  y = ++y ;
  printf("%d, %d\n",x,y);
}

    A. 10, 10

    B. 10, 11

    C. 11, 10

    D. 11, 11

6. For the following Java or C# code(3 Points)

int [][] myArray3 =
new int[3][]{
  new int[3]{5,6,2},
  new int[5]{6,9,7,8,3},
  new int[2]{3,2}};

    What will myArray3[2][2]

    returns?

    A. 9

    B. 2

    C. 6

    D. overflow

7. Please choose the right statement about const usage:(3 Points)

    A. const int a; //const integer

    B. int const a; //const integer

    C. int const *a; //a pointer which point to const integer

    D. const int *a; //a const pointer which point to integer

    E. int const *a; // a const pointer which point to integer

8. Given the following code:(3 Points)

#include <iostream>

class A{
public:
    long a;
};

class B : public A
{
public:
    long b;
};

void seta(A* data, int idx)
{
    data[idx].a = 2;
}

int _tmain(int argc, _TCHAR *argv[])
{
    B data[4];

    for(int i=0; i<4; ++i)
    {
        data[i].a = 1;
        data[i].b = 1;
        seta(data, i);
    }

    for(int i=0; i<4; ++i)
    {
        std::cout<<data[i].a<<data[i].b;
    }

    return 0;
}

    What is the correct result?

    A. 11111111

    B. 12121212

    C. 11112222

    D. 21212121

 【此题答案貌似应该是22221111】

9. 1 of 1000 bottles of water is poisoned which will kill a rat in 1 week if the rat drunk any amout of the water. Given the bottles of water have no visual difference, how many rats are needed at least to find the poisoned one in 1 week?(5 Points)

    A. 9

    B. 10

    C. 32

    D. None of the above

10. Which of the following statement(s) equal(s) value 1 in C programming language?(5 Points)

    A. the return value of main function if program ends normally

    B. return (7&1)

    C. char *str="microsoft"; return str=="microsoft"

    D. return "microsoft"=="microsoft"

    E. None of the above

11. If you computed 32 bit signed integers F and G from 32 bit signed X using F = X / 2 and G = (X>>1), and you found F!=G, this implies that(5 Points)

    A. There is a compiler error

    B. X is odd

    C. X is negative

    D. F - G = 1

    E. G - F = 1

12. How many rectangles you can find from 3*4 grid?(5 Points)

    A. 18

    B. 20

    C. 40

    D. 60

    E. None of above is correct

13. One line can split a surface to 2 part, 2 line can split a surface to 4 part. Given 100 lines, no two parallel lines, no tree lines join at same point, how many parts can 100 line split?(5 Points)

    A. 5051

    B. 5053

    C. 5510

    D. 5511

14. Which of the following sorting algorithm(s) is(are) stable sorting?(5 Points)

    A. bubble sort

    B. quick sort

    C. heap sort

    D. merge sort

    E. Selection sort

15. Model-View-Controller(MVC) is an architectural pattern that frequently used in web applications. Which of the following statement(s) is(are) correct:(5 Points)

    A. Models often represent data and the business logics needed to manipulate the data in the application

    B. A view is a (visual) representation of its model. It renders the model into a form suitable for interaction, typically a user interface element

    C. A controller is the link between a user and the system. It accepts input from the user and instructs the model and a view to perform actions based on that input

    D. The common practice of MVC in web applications is, the model receives GET or POST input from user and decides what to do with it, handing over to controller and which hand control to views(HTML-generating components)

    E. None of the above

16. we can recover the binary tree if given the output of(5 Points)

    A. Preorder traversal and inorder traversal

    B. Preorder traversal and postorder traversal

    C. Inorder traversal and postorder traversal

    D. Postorder traversal

17. Given a string with n characters, suppose all the characters are different from each other, how many different substrings do we have?(5 Points)

    A. n+1

    B. n^2

    C. n(n+1)/2

    D. 2^n-1

    E. n!

18. Given the following database table, how many rows will the following SQL statement update?(5 Points)


    A. 1

    B. 2

    C. 3

    D. 4

    E. 5

19. What is the shortest path between node S and node T, given the graph below? Note: the numbers represent the lengths of the connected nodes.(13 Points)

    

    A. 17

    B. 18

    C. 19

    D. 20

    E. 21

20. Given a set of N balls and one of which is defective (weighs less than others), you are allowed to weigh with a balance 3 times to find the defective. Which of the following are possible N?(13 Points)

    A. 12

    B. 16

    C. 20

    D. 24

    E. 28


腾讯2017暑期实习生笔试题

今天有点累,不如来个刷个题吧,记得参加腾讯在线笔试的时候遇到过一道题,确实比较懵,所以今天就好好的想了想,这个题来自牛客网... 看到这个图的时候相信大家明白了吧,就是这个题,我一直没有思路,...
  • zr1076311296
  • zr1076311296
  • 2016年06月20日 20:51
  • 3330

微软2013暑假实习生笔试题解析

所有题目为不定项选择 1. Which of the following calling convention(s) support(s) support variable-length param...
  • libing06081227
  • libing06081227
  • 2013年04月27日 21:57
  • 637

微软2013暑假实习生笔试题(有答案)

转自http://blog.csdn.net/fengbingyang/article/details/8764931 部分题目答案不确定,会持续更新…… 1. Which of the foll...
  • zhizunwudi
  • zhizunwudi
  • 2013年05月21日 10:50
  • 491

微软Microsoft 2013暑假实习生笔试题

1~8,做对3分,半对2分,错误-2分,不做0分 9~18,做对5分,半对3分,错误-3分,不做0分 19~20,做对13分,半对7分,错误-7分,不做0分 1. Which of ...
  • qiyuexuel
  • qiyuexuel
  • 2013年04月19日 11:18
  • 1181

2016网易暑期实习生笔试题

报的是研发工程实习生,抱着水一水的心态参加了(因为自己需要提高的地方实在太多...),意外接到了面试的通知,所以想在面试前把笔试题目整理一下... 先是选择题若干,感觉最多能对三分之一吧....涉及到...
  • qq_20581563
  • qq_20581563
  • 2016年04月07日 18:02
  • 2155

华为2017暑期实习生面试体会

今天到广州嘉鸿华美达酒店参加了华为2017年实习生的面试...总体感觉比较混乱,而且看到身边好多大神同学都被刷了,有点震惊,下面就讲讲体会。 首先是一面等候区,一群人坐在一个区域里,等着面试官出来叫...
  • sinat_23118323
  • sinat_23118323
  • 2017年04月08日 19:31
  • 1985

腾讯2013年实习生笔试题目

转载地址:http://www.cnblogs.com/sooner/p/3253105.html 一、选择题 1、32位机上根据下面的代码,问哪些说法是正确的?() signed ...
  • zhangyuehuan
  • zhangyuehuan
  • 2014年03月26日 22:45
  • 1202

2017年腾讯暑假实习面试总结

腾讯二面失败: 4.11收到腾讯一面的通知的时候,一种微妙的心情——激动,紧张,遗憾,开心。 我知道自己的实力,知道我并不是那种可以做到完美的人。我也知道第一次总有栽跟头的时候,但是我真的不想把跟...
  • weixin_35909255
  • weixin_35909255
  • 2017年04月20日 00:45
  • 520

微软研发类实习生面试

自己一直对微软有一种对bat没有的向往吧!所以很早就关注了微软的实习生招聘。 想成为微软的intern必须经过以下环节 笔试+一轮电话面试+3轮现场面试(中间可能穿插着跟hr谈谈) 1 笔试 先说一下...
  • martinmateng
  • martinmateng
  • 2016年05月02日 23:36
  • 8626

微软2012暑假实习生笔试题解析

1. Suppose that a Selection Sort of 80 items has completed 32 iterations of the main loop.  How man...
  • libing06081227
  • libing06081227
  • 2013年04月08日 11:05
  • 704
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:微软2013暑假实习生笔试题
举报原因:
原因补充:

(最多只允许输入30个字)