2 ms·
What's that have to do with anything? In my example the function returns a type of string which doesn't exist in C. The simplest version of the function is one
by jswinghammer 16y ago
What's that have to do with anything? In my example the function returns a type of string which doesn't exist in C.
The simplest version of the function is one that takes an integer and returns a string. This isn't a trick question and it's not difficult to answer or judge the answer if you take the time to learn it. Assuming that you're going to be hiring a programmer without one handy to help you then you need to read a few books and learn a few things. It's not that hard if you're sufficiently motivated to learn.
- alextgordon 16y agoI was illustrating the point that even the most minor of things can have many completely different looking but acceptable solutions. There's way way more than "one or two" ways to solve it if a non-programmer is judging. Non-programmers won't have a command of the language necessary to parse uncommon syntax and idioms.
- jswinghammer 16y agoIf you define the parameters correctly there are really only two ways to solve itoa that I know of. Problems like this always have rules and boundaries. Besides the people who this question would screen could not tell you what an allocator might even be.