Better HN
topnewbestaskshowjobs
Log inSign up

ThreeToZero

37 karma · joined Jan 8, 2022 (4y ago) · 7 submissions

Submissions

comment 1y ago · link · parent

> Is it so strange that after spending fifteen years of my life trying everything I could to get away from spending all day wrangling a big ball of mud in a Java IDE, that experience sounds pretty cozy to return to?

Relatable experience in software.

Also might lead to the reactionary conservatism she hated in those "frustrating programmers", that liked their toil of assembly and muddy type systems.

comment 3y ago · link · parent

The post gives an example of how python doesn't have this feature in the section [https://blog.vero.site/post/noulith#coding-with-and-without-...]

Python fails this criteria because if you type as you think through the process, you have to move the cursor to the beginning to prefix the 'map' around the input.

For example this series of transforming the input:

puzzle_input.split("\n\n")

map(ints, puzzle_input.split("\n\n"))

map(sum, map(ints, puzzle_input.split("\n\n")))

max(map(sum, map(ints, puzzle_input.split("\n\n"))))

----------------------

Compare to this postfix syntax where you can write this incrementally as you think through the operations:

puzzle_input split "\n\n" map ints map sum then max

comment 3y ago · link · parent

Haha good counter example. Well played

comment 3y ago · link · parent

A modified A* that solves the fire routing problem (less efficiently than OP's I think).

Each A* location stores where it comes from, how long it takes to get to it, and how many fires it passed through to get there. The algorithm only considers fire cells neighbors if the current number of fires passed through is less than the current fireWillingness global.

1. count fire tiles within movement range

2. run A* from src to dst completely avoiding fire

3. if we can reach then that's the solution

4. if we can't reach, increase fireWillingness to 1, re-run A* on the board

5. keep increasing fire-willingness until the A* results don't change, or we can now reach the dst.

This works because a low fire path is always better than a high fire path. And increasing fire-tolerance will only shorten the paths from src to dst.

comment 4y ago · link · parent

> depends on the block reward AND the price of bitcoin

The direct block reward goes to zero over the years, but the miner's fee will still be a positive amount.

Each miner will be competing for the miner's fee, and will buy more electricity if they can mine more blocks (and get more miner's fees).

The rewards will be proportional to the market cap of bitcoin. If it goes up, so will the investment in electricity.

> making sweeping statements here

The sweeping statements that poster made are the results of a microeconomics analysis.

There is a large & "efficient" market competing for bitcoin mining rewards by buying more electricity.

This is tapping into laws of economics on the level of supply/demand curves: Well studied scenarios that become more accurate the more efficient the market is.

comment 4y ago · link · parent

Super long is >100 character passwords. Not much point: either the hash function is broken or some other hack will happen before humanity develops enough compute power to crack 100 char bcrypt passwords.

Websites (like some banks used to) that have less-than 20 char limits for passwords are purely bad security strategy.

comment 4y ago · link · parent

Bitcoin is 'vulnerable' to this. The most common use is to put financial transactions on Bitcoin, but you can put whatever binary data you want. Famously the genesis block[1] includes a newspaper headline to prove it was created after a specific day.

It's possible to place illegal content onto the Bitcoin blockchain.

[1] - https://en.bitcoin.it/wiki/Genesis_block