Mentor Graphics :: Placement Papers
Posted by Subash | 10:36 PM
[3] Comments
C/C++
- Grade ur knowledge in c and c++ from 0 to 100
- What is virtuval distrcuctor.
- Are there any default concstructors in c++? what are they?
- What is the difference between copy constructor and Overkloading =. Why language is provided two of these?
- What are inline functions, what is the difference between #define and inline
- What is the difference between inline and normal function. will the compiler take inline functions always inline ,if not on which basis it will decide to ignore inline.
- Prog which illustrates difference between extern and static
- Virtual and Friend Function in C++
- The sequence in which constructors of classes A, B and C are called when class A is inherited from class B which is inherited from class C.
- Steps in the compilation of a C program. or steps in preprocessing in sequence.
- Differences between a reference and a pointer in C++.
- Differences between typedef and #define
- If we have a union with three variables int i, char c, float f; and we store a value in say the variable c now. and we forget what is the variable of the union that holds a value currently,
after some time. for this is there any mechanism provided by the language using which we can find out whether it is i or c or f that currently holds a value. - padding bytes for structures: suppose there is structure struct x{int x, char c}; and the compiler is a four byte compiler. then what is memory allocated to variable of this struct type. if the structure definition is struct y{char x; int y;}; then what is the memory allocated for a variableof this type.
- Prototype definition of the printf() function.
- How do you dynamically allocate a two dimensional array of size a by b.
ans: int **x;
x = (int**)malloc(sizeof(int*)*a);
for(int i=0;i - Then what if it is assigned as: int *y = (int*)x;
- Questions on declarations of function pointers in C.
- Differences between Java and C++.
- Inorder, preorder, and post order traversals.
- how do you find out if a loop(cycle) exists in a linked list,efficiently
- name the oo concepts.
- What is the light weight process ?
- Why thread is lightweight?
- What is the best Scheduling algo that will give best throughput?
- Semaphores and mutexes.
- What is that we can't do with boolean variables that can be done with semaphores?
- Question about UNIX file system.
- Inode number 0 corresponds to what?
- Name few compiler optimizations (little more about compiler optimizations)
- What is LALR parser.
- What is hill climbing?
- What is simulated annealing?
- What is piggybacking?
- Tell some differences between congestion control and flow control?
- Theory of computations
1) about various complexity classes;
2). NP-hard and NP-copmleteness,
examples;
3). what is universal Turing machine?
- There are 100 gates with doors ( 1.... 100).Intially they are open. Switching the gates ( if open then close , if closed then open ) can be done. First they will switch the multiples of 1's then they will switch the multiple's of 2's and soooo on multiple's of 100's. Now, at the end how many doors are closed and what are they?
- 10 58 ____ Ans: 3^n+7^n --> 3^3+7^3
Ans: ( 1,4,9,16,25,36,49,64,81,100)
5:13 PM
thnx,really useful information.
8:52 PM
thx a lot.really usefull information.can u give some more ....
6:30 PM
Thanks a lot for sharing this valuable information.
keep writing, your blog is more attractive.
Visit below link for more
Placement Papers