Better HN
topnewbestaskshowjobs
Log inSign up

dicroce

967 karma · joined Mar 25, 2011 (15y ago) · 336 submissions

Submissions

comment 7y ago · link · parent

I used to suck at algebra, then I wrote c++ code for 30 years... now I can see how they differ and how they are similar.

sometimes when you are programming in a big body of code you are dealing with lots of types (types in the programming sense)... and you are dealing with functions that have type signatures that must be satisfied to avoid compile errors... so you wrap this type in that one so you can call that function.. or you convert the return value from one type to another so you can call something else...

anyway, that is all similar to what you are doing when you manipulate an equation. you follow the rules and change it into a form that is more useful.

comment 7y ago · link · parent

The article I remember most from that vintage: Gang War in Cyberspace.

https://www.wired.com/1994/12/hacker-4/

comment 7y ago · link · parent

fork() explanations generally describe the api's, maybe talk a little about COW and memory protection... but I never see sufficient explanation of WHEN to use fork().

comment 7y ago · link · parent

maybe you guys should push for electric bicycles?

comment 7y ago · link · parent

I'm fine with SQL, but i would also like there to be a more explicit language that requires you to invoke the indexes when querying explicitly (instead of implicitly like SQL). If you attempted to use an index that didn't exist the query would simply fail (instead of just run slowly).

comment 7y ago · link · parent

not. there that was simple.

comment 7y ago · link · parent

I've successfully used mmap() a few times in the last few years... Luckily for me the use cases I've had weren't really subject to the same problems I've since read about here and elsewhere:

1) I'm always mmap()ing the whole file (and the files are power of 2 sized). 2) The files I'm mapping are stored on file systems I control (and so are never on NFS). 3) In one case, my use of mmap() is limited to read only.

comment 7y ago · link · parent

I tried to do this about 12 years or so ago... domain was quickymail.com.... I probably gave up too soon.

comment 7y ago · link · parent

You have to cut down the trees at maturity and preserve them and re plant in order to actually reduce carbon in the atmosphere. We should probably be doing this (as long as we're careful not release more co2 than we capture doing all this)... But we should also be putting government money behind scaling climeworks and other direct carbon capture tech... We should also be seriously studying other more drastic measures.

comment 7y ago · link · parent

yes, yes, the classical economists reaction to AI is to simply consider it equivalent to the machines of the past that replaced human labor.... in the past workers may have had to find new work but since machines need operators eventually everyone found a place... the problem is that AI doesn't replace labor, it replaces operators.

comment 7y ago · link · parent

This reminds me of DCT's...

comment 7y ago · link · parent

just knoppix itself is nostalgia'ing me pretty hard..

comment 7y ago · link · parent

Tie into the grid and get paid from your utility.

comment 7y ago · link · parent

We should be funding the shit out of Fusion and molten salt fission reactors. We're gonna also need to build shitloads of carbon scrubbers and water desalinization plants.

comment 8y ago · link · parent

Many crops would not need so many pesticides if they were grown in close proximity to the other plants they naturally occur with... in some cases this is because other plants attract predator insects that keep other insects at bay... humans could never farm this way because harvesters just chop everything down at once...

But a robot capable of recognizing all the plants could tell... and could selectively harvest just what is needed.

I suspect this is a very difficult problem however just because of how varied individual plants can be... telling plants apart can be hard even for trained humans.

comment 8y ago · link · parent

There is an estimated 100 billion nuerons in the human brain. We know from information theory that DNA is not nearly long enough to describe all of those connections. This means that most of the complexity of the brain is emergent.

I envision bundles of neurons that begin their existence mostly disconnected... These bundles are described somewhere in DNA (but not their ultimate learned configuration) and so is whatever learning algorithm drives this process.

We will have AGI when we understand the underlying learning algorithm our brain uses... Personally, I believe that algorithm involves fantasizing future scenarios and learning from the fantasies.

comment 8y ago · link · parent

I prefer this idea:

https://qz.com/1355672/stacking-concrete-blocks-is-a-surpris...

comment 8y ago · link · parent

Unqlite doesn't support in order traversal of data because the default (and only included storage engine) is based on hashing.

comment 8y ago · link · parent

I just switched to Mac for work 2 months ago... Before that I was using a 2016 Razer Blade Stealth (which I loved)...

Touchbar is worse than useless for me because I am constantly accidentally grazing the esc key on the touch bar with my ring finger... infuriating. Keyboard is pretty bad also... I needed to take my macbook to the apple store (thunderbolt issue) and so I had to use a loaner for a week... I got the last macbook before the 2017 one... SO much better! First of all having a variety of ports is awesome... keyboard is awesome... Why did they just not add 2 thunderbolt ports and a 4k screen to that one (and upgrade CPU etc)?

comment 8y ago · link · parent

so I was trying to figure out why a query was slow the other day... it was a nasty query with like 14 joins... I used explain and saw that it was a mess... now in my case I was able to switch to outer joints and nest related joins and got it fast.. but I had some interesting thoughts.

In SQL, indexes are implicit.. they are used if available but it's easy get a large query to scan sometimes when it shouldnt... what if there was a different query language with explicit index syntax.. I think you'd get a lot more predictable performance.

comment 8y ago · link · parent

WTF? This is amazing... Please be real! Please be real!

comment 8y ago · link · parent

I wrote a database for my app and it was the best decision we made.

comment 8y ago · link · parent

Personally, I think global's with constructors are kind of an anti pattern. I've noticed a high correlation between crappy app's and app's with a lot of pre main() code. Especially if some of your global's have threads: because then you potentially have threads running AFTER main exits... I've seen a number of apps with random crashes at shutdown because a thread that was started in a global was still running and since main returned globals were being cleaned up and the thread used something that had just been cleaned up.

comment 8y ago · link · parent

A few years back I became obsessed with securing a server (a previous one had been hacked). I noticed after a while that what started out reasonable (updating software, closing ports, etc)... had become unreasonable (writing custom code to detect changes to any file on the machine)... and I realized that each step normalized the next step in the sequence. The same thing is in effect with preppers.

You start with the thought "I should have some canned goods and water on hand."... 5 years later you're locked in your bunker in south dakota... each step seemed reasonable, but the destination is unreasonable.

That said, you should have some canned goods and water on hand. :)

comment 8y ago · link · parent

You know what would actually be welcome? Some way to tell real from fake news. Get to work on that, Google.

comment 8y ago · link · parent

I'm curious why it writes the whole file... Can't you do something like:

      if rollback log exists
         recover
      create log
      for each write(),
         write old contents of region to log (along w/ location)
      sync log
      for each write(),
         write new bits
      sync db file
      remove(log)

comment 8y ago · link · parent

I'm curious if anyone has created a headless browser Netflix ripper?

comment 8y ago · link · parent

https://www.youtube.com/watch?v=PDbXPBwOavc

comment 8y ago · link · parent

Here is my prediction: they will begin slowly, but eventually ISP's will be priortizing the traffic of their shitty versions of various internet services (youtube.com, DropCam, etc...)... This will impact small new businesses the worst because large entities will be able to afford to pay... So, we'll just have less new internet startups... Will be quite hard to quantify.
1
456
12