/
17.12.2017 at 12:00 am
Cuttings

To Know C

Those who know C, and those who actually don't.

... You'd be surprised at how people simply don't understand or know the basics of the language. We rather focus on how well the candidate knows the basics. Pointers are key and you should know how to use them like the back of your hand. Being able to use C data structures like structs, enums, etc. are also vital. Being able to manipulate data at both the byte level and the bit level (do you understand bit masking, bitwise logic, etc.).

When we conduct interviews, we don't focus on the algorithms or data structures that you see in higher level languages because that gets rather difficult in a language like C. We will ask things like do you know how to reverse an array or find content in strings as these require you to fundamentally understand memory, pointers, etc. and they aren't necessarily difficult algorithms. We do ask questions that try to see how well someone knows some of the tricks that you see in C, like doing multiplication/division by 2 using bit shifting, checking if a number of even or odd by bit checking instead of using modulo, etc.

Beyond the language itself, you also have to have a good understanding of how the code interacts with the OS. A big one is do you understand stack vs. heap? We may ask how you would write a function that returns an array (many candidates will try to create an array on the stack in the function which obviously doesn't work vs. using the heap or creating it on the stack in the calling function). Do you understand the basics of how functions are called and the implications of that (i.e. buffer overflows leading to security vulnerabilities)? A lot of OS basics are important to us, like understanding paging and the memory hierarchy. ...

Basically, and I think you can tell, is that we want our C developers to be more than someone who can write a C program and compile it. We want someone who understands what every line of code in the program is doing and how that program interacts with the OS and the hardware. This takes a lot of knowledge and is a lot different than higher level programming languages where such information isn’t as important as knowing how to apply the tools of the language. [...]

- Reddit

Filed under:
#
#
Words: 402 words approx.
Time to read: 1.61 mins (at 250 wpm)
Keywords:
, , , , , , , , ,

Other suggested posts

  1. 01.04.2023 at 11:27 am / Search Notes Fast: With Taskwarrior, jq & ripgrep
  2. 11.06.2022 at 09:09 pm / 大蛇に嫁いだ娘 - The Girl Married to the Giant Serpent
  3. 25.08.2020 at 08:42 am / Triple Buffered Painters
  4. 13.08.2020 at 10:00 am / Consenting Pythonic Adults
  5. 07.10.2019 at 11:22 am / 3D & 2D - The Demarcation
  6. 08.12.2017 at 12:00 am / The Song of Java Braces
  7. 03.12.2017 at 12:00 am / Declarative, Imperative, Functional Sandwiches
  8. 28.09.2015 at 12:00 am / Mocking the Law - Excessive Judicial Discretion
  9. 13.06.2015 at 12:00 am / Sexism Against Modern Men
© Wan Zafran. See disclaimer.