C Software Engineer Interview Questions

994 c software engineer interview questions shared by candidates

Task 1. You are given a string containing just numbers and mathematical operator + and *. You have to read from the string characters, one by one. If it is a digit, then push it in stack. If it is an operator, pop 2 elements from the stack, apply the operator to those elements, and push the result in stack. If you there is not enough elements in stack, or no operator to apply, return -1. For example "12+4*7*" You have to calculate a result like this: 1-> push in stack 2 -> push in stack + -> pop 1 from stack, pop 2 from stack, perform 1 + 2 and push 3 in stack 4 -> push in stack * -> pop 4, pop 3, multiply them and put 12 in stack. 7 -> push in stack * -> push 7 and 12 from stack and multiply them. Return 84. Task 2. It was about dynamic programming/ greedy algorithms. 1 day ticket costs 2 dollars, 7 day ticket costs 7 dollars (valid for sequence of 7 days), one month ticket costs 25. You are given list of increasing dates you gonna travel. You have to return minimum possible amount of money you spend on tickets. For example 1,2,3,4,5,11,12,25 Return 13.
avatar

C++ Software Engineer

Interviewed at Jump Trading

4.2
Sep 2, 2016

Task 1. You are given a string containing just numbers and mathematical operator + and *. You have to read from the string characters, one by one. If it is a digit, then push it in stack. If it is an operator, pop 2 elements from the stack, apply the operator to those elements, and push the result in stack. If you there is not enough elements in stack, or no operator to apply, return -1. For example "12+4*7*" You have to calculate a result like this: 1-> push in stack 2 -> push in stack + -> pop 1 from stack, pop 2 from stack, perform 1 + 2 and push 3 in stack 4 -> push in stack * -> pop 4, pop 3, multiply them and put 12 in stack. 7 -> push in stack * -> push 7 and 12 from stack and multiply them. Return 84. Task 2. It was about dynamic programming/ greedy algorithms. 1 day ticket costs 2 dollars, 7 day ticket costs 7 dollars (valid for sequence of 7 days), one month ticket costs 25. You are given list of increasing dates you gonna travel. You have to return minimum possible amount of money you spend on tickets. For example 1,2,3,4,5,11,12,25 Return 13.

difference among Sequences container: vector, deque, list difference among associate container: set, map, hash difference among smart pointer: std::unique_ptr, std::shared_ptr, std::weak_ptr difference between struct and class read C++ code and give result: related to virtual function and template Shell and Python questions: awk print column, Python dictionary Use C++ to realize a class: understand map, pair, struct, operator overload, class
avatar

C/C++ Linux Software Engineer

Interviewed at Exegy

2.9
Jun 13, 2015

difference among Sequences container: vector, deque, list difference among associate container: set, map, hash difference among smart pointer: std::unique_ptr, std::shared_ptr, std::weak_ptr difference between struct and class read C++ code and give result: related to virtual function and template Shell and Python questions: awk print column, Python dictionary Use C++ to realize a class: understand map, pair, struct, operator overload, class

Viewing 71 - 80 interview questions

Glassdoor has 994 interview questions and reports from C software engineer interviews. Prepare for your interview. Get hired. Love your job.