HF RL Explorer

tokenizer: edge case

tokenizer: edge case: a task in smol-software-harbor (Harbor dataset). The expression lexer in calc/lexer.py turns every - into an operator, so 3 - -1.5 and -2 4 cannot be evaluated later. As the docstring of tokenize() says, a - directly followed by a number is part of the number when it comes…

The task

The expression lexer in `calc/lexer.py` turns every `-` into an operator, so `3 - -1.5` and `-2*4` cannot be evaluated later. As the docstring of `tokenize()` says, a `-` directly followed by a number is part of the number when it comes first, right after another operator or right after `(`; otherwise it stays a…

Part of efederici/smol-software-harbor.