I'd say so. The main benefit is just to transcribing itself; it's made me able to type things character-by-character without attaching a meaning to it, which is neat for when I'm typing code I don't understand, but I think some of the more complex syntax posts have also improved my ability to type many different special characters next to each other more quickly, and that helps outside of transcribing as well.
It's not that I like pain, it's that OCR is always either 1) the same amount of effort as doing it manually, or 2) broken to the point that correcting it would be more effort.
Try figuring out the settlement date on a 6 month forward for CADMEX FX, which is a cross based on USDCAD and USDMEX: three different schedules and 2 different settlement rules.
Indeed. I've been here before. I have some code currently in production that is a big messy date parser. The reason it exists in my case is because the source system has zero constraints for how dates are input along with some really odd conventions... I can confirm it has indeed made me crazy.
Yeah. This is why I only do TypeScript. I hate dynamic languages, they're a burning pile of shit. I want to know what arguments' types will be of a function. I want to return only one type, not anything. It makes no sense for this to be possible. It just has more and more possibility of errors, at no benefit, literally no benefit.
I suppose some people prefer that as they don't have to care about whatever type they return from their functions (according to someone who was shitting on C++ some time back ? but who didn't know C++ at all), they usually don't have to do conversions,
however,
to me it feels like just moving from compile-time (or write-time, in case of interpreted languages, if that's the right term ? I'm probably wrong) errors to runtime errors, when no conversion can be made.
The API it provides is terrible. While it has been improved over the years, there's a lot of things it can't do well natively. For example, if you have to deal with timezones, it's extremely limited. You can basically only work with UTC or the current timezone of whatever computer it's running on.
The constructor function new Date(...) contains unspecified behaviour, such that implementations are just expected to reverse engineer whatever other browsers do. If you give it a date as a string that's not the defined subset of ISO-8601, it's just whatever best-effort parsing algorithm the implementation chose.
25
u/MurdoMaclachlan public boolean isInt(int i) { return true; } Jan 30 '22
Image Transcription: Code
I'm a human volunteer content transcriber and you could be too! If you'd like more information on what we do and why we do it, click here!
185
u/halfanothersdozen Jan 30 '22
You deal with dates enough it will make you crazy.
This is clearly someone who has dealt with too many dates.
8
u/articulatedbeaver Jan 30 '22
You think this is bad look at the date logic for core nlp.
4
u/brainsto Jan 30 '22
I love the ‘re‘ variable being installed in that early for-loop, but never used.
2
u/Hinduuism Jan 30 '22
This was almost sane til the return line. Wtf am i reading
2
u/T8ortots Jan 30 '22
Hehe secs
6
u/drksntt Jan 30 '22
Js is just bad. Too many dialects, too loose of a language. Too much going on there. Also can’t tell if line 7 does anything.
1
u/mrdc1790 Jan 30 '22
I don't understand this at all lmao but I am a pretty mediocre programmer
0
u/[deleted] Jan 30 '22
[deleted] — view deleted comment