4 ms·
how many lines of code do you think you could do it in?
by metalliqaz 3y ago
how many lines of code do you think you could do it in?
- gumballindie 3y agoI dont know - it’s a genuine question. I honestly didnt expect this to be a complex problem, let alone incredibly complex. I genuinely want to understand where the challenge lies.
- andruby 3y agoIf you want a datapoint, Origami is a "pure Ruby library to parse, modify and generate PDF documents". That library cloc's in at 13,683 lines of code and 3,295 lines of comments.
- gumballindie 3y agoThats not a lot of code tho, but i see your point.
- Tostino 3y agoTry getting GPT-4 to spit out that much code and have it be coherent and run together.
- bandrami 3y agoIn the case of a PDF parser it has to embed a full PostScript interpreter
- layer8 3y agoThe PDF spec is of byzantine complexity, and is full of loose ends where things aren’t fully and unambiguously specified. It also relies on various other specs (e.g. font formats), not to mention Adobe’s proprietary extensions.