cgtjsiwy

joined 1 year ago
[–] [email protected] 12 points 1 year ago

It would be much easier to read if it was actually table, i.e., if hex codes and the characters were separated into their own columns.

[–] [email protected] 58 points 1 year ago (4 children)

My workplace has the opposite problem.

The company has been in dire need of programmers for years, so they hired people (including myself) without tests. However, the work involves lots of custom iterators and the occasional handcrafted parser, which most of the company is incapable of writing. The bright side is that management has their metrics mostly right, so I'm getting lots of raises for solving fun problems.

[–] [email protected] 2 points 1 year ago (1 children)

I recommend Pyright over Mypy if you don't mind it being owned by Microsoft. It has far fewer bugs, and if you do stumble on one, you don't have to fix it yourself because Microsoft's paid devs will fix it in a couple of working days (at least for the small bugs I've reported).

[–] [email protected] 2 points 1 year ago

I do very little coding, but it's because our workplace has an abundance of junior developers, not because I'm pressed for time. My work is essentially just turning emails into technical specifications that others can implement and tutoring juniors when there are problems. Few to no pointless meetings because I insist on using emails or tickets whenever possible.

[–] [email protected] 3 points 1 year ago (1 children)

Agreed. I think operator overloading is a necessary feature in any math-oriented or general-purpose language. Being able to write formulae the same way as they're written in the source paper is a huge boon to readability.

[–] [email protected] 3 points 1 year ago

Different applications require different tests, so no measure is going to please everyone. If you're making embedded devices for an airplane, the buyer might ask you to provide a formal proof that the program works. In contrast, web apps tend to simply use end users as testers, since it's cheaper.

[–] [email protected] 3 points 1 year ago

What is the median amount of times you end up shuffling the array before it is sorted?

The answer is n! where n is length of the array.

I assume you meant mean instead of median. The median of a geometric distribution with parameter p is ceil(-1/log~2~(1-p)).

[–] [email protected] 5 points 1 year ago (2 children)

The author wanted "a more powerful type of inference that can actually infer the whole type of a function by analyzing the body of the function", which Rust doesn't have by design.

[–] [email protected] 1 points 1 year ago

I personally don't like the idea, because keeping services entirely disconnected is good for privacy.

Furthermore, I think it's funny that the author used Matrix as an example of a service benefiting from chat federation, when Matrix is about to be deportalled from Libera.Chat due to bad UX and leaking secret channels. If Matrix can't even federate properly with IRC, there's no way they can do it with modern services like Discord.

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago) (1 children)

Another point in favour of databases is simplicity of client-server communication and data models.

Many objects in WoW (not too sure about spells, but most likely them too) work such that the client asks the server for the related DB rows when it sees an object for the first time. So instead of sending code across the wire, which would be a bad idea for many reasons, you instead send structured data that the client interprets.

Of course, you could just bake the spell code into the client at compile-time, but then dataminers will take it apart on day 0. WoW datamining mostly works such that you play the game normally and see what data the server gives you.

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago)

Although I’ve used a number of languages including Python, Javascript, and Go to build software, the bulk of my experience is working in Java.

Notably, Python's type annotations are extremely similar to Typescript. I guess the author hadn't used Python's type annotations very much (which is understandable considering they're often missing from libraries and the implementations are buggier than Typescript).

[–] [email protected] 2 points 1 year ago (1 children)

In languages with static and convenient type systems, I try to instead encode units as types. With clever C++ templating, you can even get implicit conversions (e.g. second -> hour) and compound types (e.g. meter and second types also generate m/s, m/s^2 and so on).

view more: ‹ prev next ›