Monday, June 29, 2009

Intrew Q

Q:what is exclusive OR?
Q:what is differnce between sequence diagram & collaboration diagram?
Q:what is Struct?
Q:why u intrested in porgramming?
Q:why Normalization ?
Q:what is OpenGL?
Q:what is differnce between button created in C & openGL?
.
.
.
.

Saturday, June 6, 2009

Find The Complexity

Q: Find Complexity of the Following Code:


int j=0;
for(int i=2; i less than N;i=i^2)
j++;

Hint: it is not lg(N)

Thursday, June 4, 2009

Some HR Questions

1) Tell me something about yourself and your interests

2) Tell me something about some problems you faced in a project and how did you handle it?

3) Give one instance where you were criticized by your Professor

4) Where do you see yourself five years from now?

5) What salary are you expecting?

6) Any Questions for me regarding the position or the company?

7) Finally, does this position sound interesting? :-)

Question 7 (C/C++)

1) How would you decide weather to use C, C++ or Perl for a particular project?

2) What are pointers? Why do we use them?

3) What are the benefits of having Global & Local Variables?

4) What is 'malloc'? Why do we need to use it?

5) Write a C program to compare two arrays and write the common elements in another array

6) Write a function in C to accept two integers and return the bigger integer

7) What are the advantages of C over Perl and vice versa?

8) What does '@' and '&' mean in Perl?

9) What is a 'Package' in Perl?

10) What are Perl Regular Expressions?

11) Perl Regular Expressions are greedy. What does that mean?

12) What are Associative arrays in Perl?

13) Suppose a Perl variable has your name stored in it. Now, how can you define an array by the name? (i.e., you have $a="Adarsh"; now you want @Adarsh=[.....])

14) Write a Perl script to parse a particular txt file and output to another file in a desired format. (You can expect the file to have some data arranged rows & columns)

15) Suppose you have the outputs of a test program in some big test file. In Perl, how can you test if all the outputs match a particular string?

16) What are Data Abstraction and Data Encapsulation?

17) Explain Friend Functions and Polymorphism with examples

18) Commands for changing directory, making directory, going up one directory, knowing the file permissions and changing file permissions.

19) How do you search for a particular string in all the text files in current directory from command line?

20) How do you sort a file alphabetically from command line?

Question 6(Computer Architecture)

What is pipelining?

2) What are the five stages in a DLX pipeline?

3) For a pipeline with 'n' stages, what�s the ideal throughput? What prevents us from achieving this ideal throughput?

4) What are the different hazards? How do you avoid them?

5) Instead of just 5-8 pipe stages why not have, say, a pipeline with 50 pipe stages?

6) What are Branch Prediction and Branch Target Buffers?

7) How do you handle precise exceptions or interrupts?

8) What is a cache?

9) What's the difference between Write-Through and Write-Back Caches? Explain advantages and disadvantages of each.

10) Cache Size is 64KB, Block size is 32B and the cache is Two-Way Set Associative. For a 32-bit physical address, give the division between Block Offset, Index and Tag.

11) What is Virtual Memory?

12) What is Cache Coherency?

13) What is MESI?

14) What is a Snooping cache?

15) What are the components in a Microprocessor?

16) What is ACBF(Hex) divided by 16?

17) Convert 65(Hex) to Binary

18) Convert a number to its two's compliment and back

19) The CPU is busy but you want to stop and do some other task. How do you do it?

Question 5

1) Give two ways of converting a two input NAND gate to an inverter

2) Given a circuit, draw its exact timing response. (I was given a Pseudo Random Signal Generator; you can expect any sequential ckt)

3) What are set up time & hold time constraints? What do they signify? Which one is critical for estimating maximum clock frequency of a circuit?

4) Give a circuit to divide frequency of clock cycle by two

5) Design a divide-by-3 sequential circuit with 50% duty circle. (Hint: Double the Clock)

6) Suppose you have a combinational circuit between two registers driven by a clock. What will you do if the delay of the combinational circuit is greater than your clock signal? (You can't resize the combinational circuit transistors)

7) The answer to the above question is breaking the combinational circuit and pipelining it. What will be affected if you do this?

8) What are the different Adder circuits you studied?

9) Give the truth table for a Half Adder. Give a gate level implementation of the same.

10) Draw a Transmission Gate-based D-Latch.

11) Design a Transmission Gate based XOR. Now, how do you convert it to XNOR? (Without inverting the output)

12) How do you detect if two 8-bit signals are same?

13) How do you detect a sequence of "1101" arriving serially from a signal line?

14) Design any FSM in VHDL or Verilog.