C Software Developer Interview Questions

3,500 c software developer interview questions shared by candidates

1) What does the following code do? 2) What changes would you make to improve the code (not regarding performance)? void func(int array[ARRAY_SIZE]) { int p = 0; for (int r = 0; r < 4; r++) { for (int i = p; i < ARRAY_SIZE; i++) { if (array[i] % 5 == r) { if (i != p) { int temp = array[p]; array[p] = array[i]; array[i] = temp; } p++; } } } }
avatar

C++ Software Developer

Interviewed at Mobileye

3.8
Dec 31, 2024

1) What does the following code do? 2) What changes would you make to improve the code (not regarding performance)? void func(int array[ARRAY_SIZE]) { int p = 0; for (int r = 0; r < 4; r++) { for (int i = p; i < ARRAY_SIZE; i++) { if (array[i] % 5 == r) { if (i != p) { int temp = array[p]; array[p] = array[i]; array[i] = temp; } p++; } } } }

1st (Technical) : First round took more than 1 hour. In this interviewer asked Basic Technical question related to c++. Mostly question are from constructor, virtual function, Pointers and Inheritance. 2nd (techinical) : Second round took hardly 15 minutes. In this round question related to debugging is asked. 3nd ( HR) : this round took 15 minutes. In this HR asked about salary and family background.
avatar

Software Engineer (C++ Developer)

Interviewed at Dion Global Solutions

3.1
Dec 22, 2013

1st (Technical) : First round took more than 1 hour. In this interviewer asked Basic Technical question related to c++. Mostly question are from constructor, virtual function, Pointers and Inheritance. 2nd (techinical) : Second round took hardly 15 minutes. In this round question related to debugging is asked. 3nd ( HR) : this round took 15 minutes. In this HR asked about salary and family background.

Viewing 111 - 120 interview questions

Glassdoor has 3,500 interview questions and reports from C software developer interviews. Prepare for your interview. Get hired. Love your job.