4 ms·
This would match your specification. def string_to_int(str): return 1
by collyw 13y ago
This would match your specification.
def string_to_int(str):
return 1
- deleted 13y ago[deleted]
- deleted 13y ago[deleted]
- coreyoconnor 13y agoThat would match the initial specification. The point is for the candidate to note that the initial specification is too ambiguous and determine what they do about it. If they gave that answer and then said "which is why the specification is weak" then great! If they gave that answer and called it done... well... not so good.
- deleted 13y ago[deleted]