Coding Games and Programming Challenges to Code Better
Send your feedback or ask for help here!
Created by @nguyen.lam,validated by @Razovsky,@Regulus136 and @Drunkey.
If you have any issues, feel free to ping them.
Coding Games and Programming Challenges to Code Better
Send your feedback or ask for help here!
Created by @nguyen.lam,validated by @Razovsky,@Regulus136 and @Drunkey.
If you have any issues, feel free to ping them.
I think the test cases are missing many edge cases: e.g.
insert
, begin
, end
, or --
strings within a string literal;insert
, begin
, end
, or '
strings within a comment;insert
with several of its lines ending with a comment (not just after the final ;
)begin
… end
blocksI’m afraid writing a proper SQL tokenizer is no longer “easy”… So the text should indeed have mentioned the simplifications made, especially regarding strings.
Other missing tests include spaces before or after a ‘;’, as well as at the start of a line (which has been specifically pointed out as possible for ‘insert’).
Hi to all, and thanks to @nguyen.lam for this “parsing” puzzle
!
I don’t know yet about SQL requests, but i know a bit about parsing text data using machine state …
→ and this one is not specially a difficult one.
Thanks for this pleasant exercise, and to the Aprovers too (Razovsky, @Regulus136 and @Drunkey) !
Have sun , fun
and CodinGames
…
!