0% found this document useful (0 votes)
34 views9 pages

Interview Question

The document is a comprehensive set of interview questions prepared by Kittu Patel, covering topics in digital electronics, C programming, and Verilog. It includes questions on number systems, Boolean algebra, combinational and sequential circuits, data types, control statements, and more. Each section contains multiple questions designed to test knowledge and understanding of fundamental concepts in these areas.

Uploaded by

Mayur Balpande
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views9 pages

Interview Question

The document is a comprehensive set of interview questions prepared by Kittu Patel, covering topics in digital electronics, C programming, and Verilog. It includes questions on number systems, Boolean algebra, combinational and sequential circuits, data types, control statements, and more. Each section contains multiple questions designed to test knowledge and understanding of fundamental concepts in these areas.

Uploaded by

Mayur Balpande
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:infoex31@gmail.

com

DIGITAL ELECTRONICS
1. Number Systems & Conversions

1. Convert 1101101 binary to decimal.


2. Convert 47 decimal to hexadecimal.
3. Convert 7F hexadecimal to binary.
4. What is 1’s and 2’s complement of 101011?
5. Represent -25 in 8-bit 2’s complement form.

2. Boolean Algebra & Logic Gates

6. Simplify: A + AB = ?
7. Apply De Morgan’s Theorem to: ¬(A + B)
8. Draw logic gate representation for F = AB + A'C.
9. Prove: A + A'B = A + B.
10. What is the dual of the Boolean expression A + AB?

3. Karnaugh Maps (K-Map)

11. Simplify using 2-variable K-map: F(A,B) = Σ(1,2)


12. Simplify using 3-variable K-map: F(A,B,C) = Σ(1,3,5,7)
13. What is the minimized expression of F(A,B,C,D) = Σ(0,1,2,5,6,7,8,9,10,14)?
14. How many cells are there in a 4-variable K-map?
15. What is a "don’t care" condition in K-map simplification?

4. Combinational Circuits

16. Design a 2:1 multiplexer and write its Boolean expression.


17. How many select lines are required for an 8:1 MUX?
18. Design a 3-bit binary adder using full adders.
19. What is the use of an encoder? Design a 4-to-2 encoder.
20. Differentiate between decoder and demultiplexer.

1
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

5. Sequential Circuits

21. What is the function of a D flip-flop?


22. Write the truth table of JK flip-flop.
23. Design a 2-bit synchronous counter.
24. What is the difference between latch and flip-flop?
25. Explain race condition in flip-flops.

6. Counters

26. Design a 3-bit asynchronous up counter using T flip-flops.


27. What is the modulus of a counter? Give an example.
28. Explain ring counter and Johnson counter.
29. What is the difference between ripple and synchronous counters?
30. What is the terminal count of a 4-bit binary counter?

7. FSM (Finite State Machines)

31. What is the difference between Moore and Mealy machine?


32. Draw a state diagram for a sequence detector for 1011.
33. How to minimize states in FSM using partition method?
34. Define state encoding with examples.
35. What are the practical applications of FSM in digital systems?

8. Timing Diagrams

36. Draw timing diagram of D flip-flop for one clock cycle.


37. Interpret a setup and hold time violation.
38. What happens when input changes during the clock edge?
39. Explain propagation delay with a timing diagram.
40. Analyze output waveform for SR latch with given inputs.

2
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

9. Logic Families

41. Compare TTL and CMOS logic families.


42. What is fan-out and why is it important?
43. What is propagation delay in logic families?
44. Explain noise margin and its significance.
45. Why CMOS is preferred in VLSI over TTL?

10. Miscellaneous

46. What is metastability in flip-flops?


47. Differentiate between asynchronous and synchronous inputs.
48. What are hazards in combinational circuits? Types?
49. Explain setup and hold time with real-time examples.
50. What is the significance of clock skew in digital design?

3
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

C PROGRAMMING
1. Data Types & Operators

1. What is the output of: sizeof(char) + sizeof(int) on a 32-bit system?


2. What’s the difference between float and double in terms of precision?
3. What will be the result of: 5 + 2 * 3?
4. How do bitwise operators differ from logical operators?
5. What is the value of 5 << 2?

2. Variables & Storage Classes

6. Differentiate between auto, register, static, and extern.


7. What happens when a static variable is declared inside a function?
8. How does extern help in multi-file projects?
9. Write a program to demonstrate register keyword.
10. What is scope and lifetime of a variable?

3. Control Statements

11. What is the difference between break and continue?


12. Write a program to print even numbers between 1 and 100 using for.
13. How is a switch statement better than if-else?
14. What’s the output of:

int i = 0;
while(i < 5) printf("%d ", i++);

15. Write a do-while loop that runs at least once, even if the condition is false.

4. Functions

16. What is the difference between call by value and call by reference?
17. Write a recursive function to calculate factorial.
4
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

18. What is the use of void in function declaration?


19. Can we declare a function inside another function in C?
20. How do you return multiple values from a function?

5. Pointers

21. What will be the output of:

int a = 5; int *p = &a;


printf("%d", *p);

22. What is a dangling pointer?


23. Differentiate between *p++ and (*p)++.
24. What is the significance of pointer to pointer (**ptr)?
25. How to dynamically allocate memory using pointers?

6. Arrays & Strings

26. Declare and initialize a 2D array of size 3x3.


27. Write a program to reverse a string without using strrev().
28. How do you pass an array to a function?
29. What is the difference between char s[] = "abc" and char *s = "abc"?
30. Find the output:

char str[] = "hello";


printf("%c", *(str + 1));

7. Structures & Unions

31. Define a structure for storing student info with name, roll, and marks.
32. What is the difference between structure and union?
33. How to pass structure to a function?
34. Can a structure contain a pointer to itself?
35. What is padding in structure?

5
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

8. Dynamic Memory Allocation

36. What’s the difference between malloc() and calloc()?


37. How to reallocate memory for an array using realloc()?
38. Why is it important to use free()?
39. Write a program to allocate memory for n integers.
40. What happens if we don’t free dynamically allocated memory?

9. File Handling

41. Difference between fopen() modes: "r" vs "w" vs "a"?


42. Write a C program to read a file line by line.
43. How do you check if a file exists in C?
44. What is the use of fseek() and ftell()?
45. What’s the difference between getc() and fgets()?

10. Miscellaneous / Advanced

46. What is a segmentation fault? How can you avoid it?


47. Explain use of const keyword with pointers.
48. What is a memory leak?
49. What are command line arguments in C?
50. Can you write a simple macro? How do macros differ from functions?

6
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

VERILOG

1. Basics of Verilog

1. What is the difference between reg and wire?


2. What are the design units in Verilog?
3. Explain the difference between module and endmodule.
4. Write a simple Verilog module for a NOT gate.
5. How do you instantiate a module inside another module?

2. Data Types & Operators

6. What is the difference between initial and always blocks?


7. What are the different types of literals in Verilog?
8. Explain reduction operators with an example.
9. What’s the purpose of parameter and how do you use it?
10. How is defparam different from parameter?

3. Procedural Blocks

11. What is the difference between blocking (=) and non-blocking (<=) assignments?
12. What is sensitivity list and how does @(*) work?
13. Write an always block to describe an AND gate.
14. When should you use initial block?
15. How to create combinational logic using always?

4. Combinational Circuit Design

16. Write Verilog code for a 2:1 multiplexer using assign.


17. Design a 4-bit adder using full adders.
18. Write a priority encoder code in Verilog.
7
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

19. Create an 8:1 multiplexer using case statements.


20. Write Verilog for a 3-to-8 decoder.

5. Sequential Circuit Design

21. Write Verilog code for a D flip-flop with synchronous reset.


22. Implement a JK flip-flop using behavioral modeling.
23. Design a 4-bit synchronous counter.
24. What is the difference between latch and flip-flop in Verilog?
25. Create a simple shift register in Verilog.

6. FSM (Finite State Machines)

26. What is the difference between Moore and Mealy FSM in Verilog?
27. Design a FSM for detecting 1011 sequence.
28. What are the states in a 3-state FSM?
29. How to represent state encoding in Verilog?
30. How to avoid latches in FSM?

7. Testbenches

31. How do you write a testbench for a 2:1 MUX?


32. What is $monitor, $display, and $finish in Verilog?
33. How to use #delay in a testbench?
34. How do you provide stimulus to DUT in Verilog?
35. Explain how to simulate a flip-flop using testbench.

8. Memories and Arrays

36. How do you declare and use arrays in Verilog?


37. Write Verilog code for a ROM.
38. How do you model a synchronous RAM?
39. What’s the difference between initial and always block for memory modeling?

8
INTERVIEW QUESTION PREPARED BY KITTU PATEL Email:[email protected]

40. How do you access a 2D array in Verilog?

9. Synthesis vs Simulation

41. What constructs are synthesizable in Verilog?


42. Which Verilog statements are non-synthesizable?
43. Explain race conditions and how to avoid them.
44. What happens if blocking assignments are used in sequential logic?
45. What are latch inference issues in Verilog?

10. Miscellaneous & Practical Scenarios

46. What is the purpose of $time and $strobe?


47. How to avoid unintentional latches in a case statement?
48. What is a sensitivity list mismatch and its effect?
49. What’s the importance of reset signals in designs?
50. How can you parameterize a module in Verilog?

You might also like