0% found this document useful (0 votes)
30 views12 pages

Interview - Questions - Week 1-2025

The document covers various technical topics including Linux internals, microcontrollers, embedded systems, data structures, C++, advanced C, functions and pointers, strings, storage classes, advanced pointers, user-defined data types, preprocessor directives, and Python programming. Each section contains specific questions and programming tasks related to the respective topics. The content is designed for individuals looking to deepen their understanding of these subjects through practical examples and theoretical explanations.
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)
30 views12 pages

Interview - Questions - Week 1-2025

The document covers various technical topics including Linux internals, microcontrollers, embedded systems, data structures, C++, advanced C, functions and pointers, strings, storage classes, advanced pointers, user-defined data types, preprocessor directives, and Python programming. Each section contains specific questions and programming tasks related to the respective topics. The content is designed for individuals looking to deepen their understanding of these subjects through practical examples and theoretical explanations.
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/ 12

Linux Internals :

a) Networking :
1. You are given an IP address 192.168.5.0 and need to
create 16 subnets. What would the subnet mask ?
2. Ubuntu comes under which OS ?
3. What is the maximum number of IP addresses that
can be assigned to hosts on a local subnet that uses
the 255.255.255.224 subnet mask?
4. What is the subnet id of a host with an IP address
172.16.66.0/21?
5. If an Ethernet port on a router were assigned an IP
address of 172.16.112.1/25, what would be the valid
subnet address of this host?
6. Determine the total number of valid IPs in each
subnet for the given IP 192.168.10.0/26 using the
CIDR value.

Microcontrollers :

a) Communication protocols :
1. What do you mean by communication protocol and
where it is used ?
2. Explain about UART, SPI , I2C and CAN protocol in
Details
3. Differences between I2C and SPI
4. How I2C is working(Sending and receiving)
5. Which protocol is used for the Car black Box project?
And explain how it's working?
6. Describe about standard frame format of CAN.
7. What are the Types of errors in CAN?
8. What are the difference between UART and I2C
9. Where we use UART and where we use I2C?
10. which are receiver side error and transmitter side
error in CAN ?
11. Difference between microcontroller and
microprocessor
12. What are the uses of microcontroller and
microprocessor ?

b) Embedded Systems :
13. Explain about the car black box
14. What is interrupt?
15. How many bits are in the data bus of 8051?
16. How many bits are transfered in 1 sec in 8051?
17. How many datatypes are there in embedded C?
18. Explain about the temperature Sensor
19. List out differences between Register and EEPROM
20. Explain Volatile Memory and Non-Volatile Memory.
21. How microcontroller communicate with devices ?
22. what is duty-cycle?

Data Structures :
1. You have two arrays, add the two arrays elements in
one sorted Single linked list.
2. Explain about the Create node
3. Write a program to delete a node with a specific value
from a singly linked list
Original List: 10 -> 20 -> 30 -> NULL
4. Write a program to merge two sorted singly linked lists
into a single sorted linked list. For example, given two
lists {1, 3, 5} and {2, 4, 6},

C++ :
1. Explain about late binding .

Advanced C :
a) Basic Refresher:
1. How to set a bit and count the number of set bits ?
2. Explain about constant keyword
3. Data types and size
4. int main()
{
for(char a = 10; a < 300; a++)
{
printf("a = %d\n", a);
}

return 0;
}
What is the output of this code?
5. How many nibbles are present in 1 byte ?
6. Take a integer variable, set the bits(pos given by
client) and print output.
7. Type conversion(implicit and explicit).why implicit type
conversion happen give an example.
8. Can the size of datatypes be changed ?
9. char var=600; is the statement correct? Explain
10. What are qualifiers. explain different qualifiers in C?
11. difference between logical and bit-wise operator.
12. What will be the output of the program ?. If there is
any error, what is the error and what is the reason
#include<stdio.h>
int main()
{
int i=32, j=0x20, k, l, m;
k=i|j;
l=i&j;
m=k^l;
printf("%d, %d, %d, %d, %d\n", i, j, k, l, m);
return 0;
}

b)Functions and pointers :


13. Which of the following return type cannot be used
for a function in C? (Options :- char* ,struct ,void ,int*)
14. Write a function to count the number of even
numbers in an array .
15. What will happen to the recursive function call
continuously?
16. What do you mean by void pointer?
17. #include<stdio.h>
int main(){
int i = 5;
void *ptr;
ptr = &i;
printf("\nValue of iptr = %d ", *ptr);
return 0;
}
Tell whether the code is correct or wrong. Why?
18. Explain about the call by reference and call by
variable with an example
19. Explain the Pointer & its types
20. What is the use of pointer, explain with example.
21. What is null pointer ? what is the size of null
pointer?
22. does context switching happens in inline function?
23. What are the ⁠difference between pointer to const
and const pointer?
24. (⁠int const *p = &var) what is this? Explain.
25. What is function declaration and function definition.
26. int var=0x12345678; explain your approach to
extract 34 and write the code.
c) Strings:
27. Write a program for my_strcat()
28. What the difference between array and string?
d)Storage Classes and memory segments:
29. Explain about static local and static global
30. Static variables stored in which segments ?
31. Why heap is needed?
32. List out the differences between malloc and calloc
33. Explain about the storage classes.
34. What is the use of the register keyword?
35. What do you mean by memory leakage?
36. what is the use of the Static keyword and where we
can use it ?
37. Explain about volatile and const
38. Difference between static and dynamic memory
allocation
39. How will you allocate the memory dynamically?
40. What will happen, if we don't free the memory at the
end of the program?
41. Can i access a static variable using extern?
42. What is the use of code segment. what is stored in
code segment ?
43. how to access the static variable outside the file?
44. where the memory is allocated for the string. can
we change the string
#include<stdio.h>
int main()
{
char *str;
str = "%s";
printf(str, "K\n");
return 0;
}
e) Advanced Pointers and functions :
45. Write a program to define 6*6 matrix.
46. What are function pointers?
f) User Defined Data types :
47. Write a program to calculate the total and average
marks of a student using pointers to structures.
48. Define a structure Student with fields:
name (string of 50 characters), roll_no (integer),
marks (array of 5 floats).
Use structure pointers to:
Input the student's details, Calculate the total and
average marks and Display the details.

49. What's the use of typedef and give an example.


50. Why do we use enum and give an example
51. Difference between structure and union
52. What is macro and tell the use of it.
53. Explain about User defined data types
54. struct structure
{
int a;
Char b;
Char arr[4];
};
What is the sizeof this structure ?
55. What is structure padding?

56. When we can use structure and when we can use


union ?
g) Preprocessor :
57. What is macro and Define a macro to reset the bit
in a given position.
58. Write a program to find largest of two numbers
using macro
59. Describe about compilation stages
60. What is #define #ifdefine, macro. Give an example
of a macro.

Python :
1. Given an array arr[] of size n, Write a program to
rearrange it in alternate positive and negative manner
without changing the relative order of positive and
negative numbers. In case of extra positive/negative
numbers, they appear at the end of the array.
Example: Input: arr[] = {1, 2, 3, -4, -1, 4}
Output: arr[] = {1, -4, 2, -1, 3, 4}
2. Write a program to reverse a string while keeping
special characters in their original positions.
Example:
input_string = "a@bc%d$e"
output_string = "e@dc%b$a"
3. Write a program to find smallest missing positive
number .
Example:
Input: arr[] = {2, -3, 3, 5, 1, 7}
Output: 4

4. Write a program to remove a character(s) from a


string to make it a palindrome.
Example:
Input : str = “Never odd nor even”
Output : Yes

You might also like