Hacker Newsnew | past | comments | ask | show | jobs | submit | devmop's commentslogin

If you've got nothing to hide then you should just let law enforcement install CCTV in your bathrooms and bedrooms.


It takes the same (huge) amount of time for all inputs - there's no early exit it always scans to INT_MAX. Hence O(1)


This is incorrect. Putting a finite bound on n does not reduce n to 1. n is always meant to be a finite arbitrarily large value. n=INT_MAX qualifies as arbitrarily large, especially on a 64-bit system.


Big-O notation says nothing about the overall absolute size. All that matters is how the amount of work scales with the input value.

If an algorithm will always take 1 billion years to complete regardless of the input, then it's still O(1).


O(x) = O(1) if x is some finite constant.


Consider n=INT_MAX*2 or INT_MAX^2 though.

The behaviour does flatline as n approaches infinity


There is no bound on n, it always searches to INT_MAX regardless of n.


It's ugly either way but for clarity you can move the error checks into the transformation leaving the call point clean.

i.e transform1 returns (result, error) and transform2 accepts (result, error) and short-circuits if err is not nil.

It allows the expressive and succinct description of a transformation list but with a bunch of messiness hidden.


This isn't ideal, because it forces each successive function that takes a Result type to add handling code in the case of an error.

fn(fn(fn()?)?)? is a bit gnarly but better than duplicate code like that, imo.


something something Maybe monad


Why not just move to 3.0? Semver only says that a breaking change MUST be an increase to the major version. It doesn't proscribe an increase of the major version without a breaking change.


Yes! Semver is very precisely specified and the specification ain't very long. How on Earth could they mess it up?


Because its summary does not exactly agree to the specification.

> Given a version number MAJOR.MINOR.PATCH, increment the: MAJOR version when you make incompatible API changes, MINOR version when you add functionality in a backwards-compatible manner, and PATCH version when you make backwards-compatible bug fixes.


A point not highlighted in OP article is that Enterprise customers are shy to upgrade to a "next major version" because they will _assume_ there are breaking changes in there (even though semver allows bumping the major number without breaking changes).

Calver side-steps this user bias.


Why are developers always insistent on trying to trick the user into doing what they want them to do, or what they think is best, instead of letting users do what users want to do?

Users shy away from major version numbers because they are allowed to change things in incompatible ways. When you jump a major version you're signaling that stuff might intentionally break, and they make their decisions accordingly. The solution is not to make your communication with user even worse!


This could easily be solved by something along the lines of “Version 3.0 maintains full compatibility with Version 2.2” at the top of their release notes.

I dislike the idea of going away from SemVer just for marketing purposes. At least as a user when I’m going to upgrade versions then I could see that “oh, this version doesn’t break compatibility”


>Calver side-steps this user bias.

Well, no, it just means users won't update at all, because every version could be breaking...


Looks like a mistake. I think the first diagram under redirection is supposed to be about the ls redirection instead


Even they've gone down that route. 4chan's been split into two domains with the NSFW boards on the original and the SFW boards (or as safe as 4chan ever gets) on the other.


What risk? That they'd spend money on something that made them no/less money?

Other than their initial investments business owners are protected from almost all the risks their businesses take on. Company debts aren't personal debts and individuals can't be forced to work to repay the debts they cause the business to take on. Worse still these safety nets aren't paid for as these companies don't make a profit.

Whilst I won't discount the work Bezos has done the reason he's come out 1000s of times better off than other Amazon workers is because of his initial gamble.

It's not like the workers don't take on risks either. Almost all paid work is paid after the fact. If your employer goes bust you don't get paid


> What risk?

Financial, health, relationships, reputation, opportunity are some of the risks.

Are you saying that an employee getting a salary has the same risks as an entrepreneur?


In what way do employees not also take all of those risks? The degree of risk might be different but employees are also betting on the success of your business. You only have to look at the recent US election to see that people are taking all these risks.

Whilst I imagine a lot of people on HN see these risks as negligible they do still exist and it can go wrong.


> The degree of risk might be different but employees are also betting on the success of your business.

The degree of risk is completely different. We can keep on arguing but there are some things you will only understand when you take the leap yourself.


The quote is from a UK report


In that case it lines up exactly


I'd like to see an ad-network which you can pay and they'll serve you transparent ads instead.

The underlying content providers still get their pay per view, the ad network is still in the loop and no one needs to implement anything new - the technology is already built.


Amazon logistics at least do Sunday deliveries as well. Far too many stores have "next day delivery" for which ordering on Friday night means it doesn't arrive until Tuesday.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: