HNHacker News
TopNewBestAskShowJobs

ilitirit

2,562 karma · joined March 3, 2008

submissionscomments
ilitirit··on Things I Enjoy in Rust: Error Handling
> Rust's advantage is that it forces you to at least pretend to handle the error

I'm not sure I would call this an advantage. See: Handling of Checked Exceptions in Java.

ilitirit··on Things I Enjoy in Rust: Error Handling
> It would translate to try-catch that wraps the entire body of the method

It would not not be the same unless you change how scoping works in these instances, and that can introduce other complexities, e.g. how to limit scope so that some things are inaccessible to the catch block.

ilitirit··on Nuclear power is the fastest way to slash greenhouse gas emissions, decarbonize
This varies by region. In the US transport and coal power are equal in terms of their contribution. In Nigeria it's diesel and deforestation. But I will concede that it's not "minor" (not sure why I said that...)

I'm not saying that coal is good or nuclear is bad or vice versa. As I said in my original comment, there is no one practical (in terms of safety, efficiency, cost etc) global energy solution right now. I don't believe any coal-powered plants should be built. Should existing ones be replaced by nuclear? Depends on the actual area, geo-political situation (which changes over time) etc.

ilitirit··on Nuclear power is the fastest way to slash greenhouse gas emissions, decarbonize
Anything is "arguably" worse or better. But honestly, I would challenge that point any day. As much as I'm against fossil fuels, coal powered plants only contribute a very minor part to global warming compared to lets say... ships, planes and cars. And my point is not about coal specifically - it was just mentioned because that's what the main opposition is to nuclear. Not solar/wind/water.

My point is that failure of nuclear energy provision is demonstrably worse than the failure of any other options we've tried. Does this mean it's better/worse? Who knows.

But you simply cannot say that something is safe if <xyz>, especially when history says otherwise.

I'm flabbergasted at the number of people talking unironically about "human error" as if it's historically insignificant...

ilitirit··on Nuclear power is the fastest way to slash greenhouse gas emissions, decarbonize
> My point is that nuclear power is safe, as long as all disaster scenarios are taken into account

To be honest, you could probably make that argument for anything under question in any scenario. But even if we were to skip the logical loopholes ("We took it into account, but we decided the benefits outweighed the costs because of <fill in any reason>"), let's just look at the raw numbers or simply just historical facts. Have any disasters at coal plants rendered areas uninhabitable for centuries? OK, take one step back. Would those disasters have occurred if "all disaster scenarios [were] taken into account"?

The reality is that we have no one good and practical energy solution for the world. And even though I believe that there's no practical solution that can beat a tried and tested solution like nuclear in terms of efficiency, I also believe that there's been no tried and tested solution that's been worse in terms of failure.

ilitirit··on SQL databases come up with algorithms you’d never have dreamed of (2017) [video]
Is SQL no longer featured as part of most Comp Sci/IS courses any more?
ilitirit··on Ask HN: Is it just me, or is CSS too damn hard?
The "hardest" part of CSS to me is accounting for minor browser differences.
ilitirit··on Confessions of an Abstraction Hater
This is simply an issue of naming, ensuring people fully understand the problem, and having the appropriate level of granularity (not necessarily abstraction).

Consider these within the context of the A->B->C->D example he gave:

    PutLeftLegForward();

    PutRightLegForward();

vs

    // Wrapper that utilizes the above functions
    Walk(numberOfSteps);
ilitirit··on Nim in 2018: A short recap
> * python 3 (without any library or optimization) was faster than compiled nim to count words on a moderately large text.

I'm sure many other commenters have singled out this comment, but do you have an example? I find this quite hard to believe. Surely this would have manifested elsewhere and people would have pointed it out ages ago? Nim compiles (or transpiles, if you prefer) to C/C++, after all.

ilitirit··on Teachers Quit Jobs at Highest Rate on Record
As a "previously disadvantaged" South African whose mother was quite "high" in the education hierarchy - she set the final year national exams for high-school students one year in one subject and moderated examiners' marks for many years before and after that - I find this quite interesting.

Well, interesting is perhaps not the right word.

Disgusting.

Not at America, but toward my country's own education system.

My mother never cared about the money. In fact, she was offered huge salaries from so-called private schools (the wording/nomenclature is a story for another time). She never took it. Her main goal was always education for students who she felt were disenfranchised. Growing up, I'd often see her very sad about a bright student who got killed because of their surroundings or something else regarding their upbringing. But she always remained determined!

It breaks my heart these days to see that she is unhappy not because she is not able help the same students from the same backgrounds, but because she simply REFUSES to. She does not believe my country's education system is equipped to give them what they need. So, instead of taking a big salary from government (she is officially retired, btw) to teach "previously disadvantaged" students in government-endorsed programmes, she does it gratis when the students approach her personally.

I just realised why I never mentioned why she doesn't sign up for "government-sponsored" initiatives in terms of education. She - as do I - simply believes the standard they expect is not of the quality that should be given to the youth. So she will rather offer her standard "for free". I hope I don't have to explain why her method is not compatible with the paid-for alternative...

ilitirit··on Photons, Quasars and the Possibility of Free Will
> Maybe randomness is free-will but it slowly erodes away with time.

It's a bit tricky depending on your idea of what "free will" means, but essentially it can be argued that there's a difference non-trivial difference between free will and determinism.

If the development of the Universe is predetermined, then the Universe is deterministic (in some system of logic) and free will does not exist.

If the development of the Universe depends on the the outcome of truly random events, then the universe is non-deterministic, but this does not imply that free will exists.

Consider: Someone has to decide between two choices which for all intents and purposes are exactly the same when measured against each other. On the most fundamental level, the only way to break the deadlock is through a "random" selection. If this random selection is driven by the aforementioned random (possibly quantum) events, then is this really "free will"? After all, the person making the decision has no conscious control of the events influencing the decision process on that level. This implies that decision making ("will") is just a function acting on inputs.

ilitirit··on 'Super Mario Bros.' speedrunner hits nearly inhuman 4:55 world record
Yes, but this is referring to a specific TAS (the current fastest* known one), not a possible TAS.

http://tasvideos.org/Game/nes-super-mario-bros.html

[*] It's also worth noting that there are 2 categories for TAS timing: Humanly possible vs TAS-only. The former meaning that it's possible in theory for a human to achieve under "normal" conditions, the latter implying the opposite e.g. using left + right inputs at the same time which is not possible on a normal NES pad. The TAS in question was the current theoretical limit for humans.

ilitirit··on 'Super Mario Bros.' speedrunner hits nearly inhuman 4:55 world record
> It means he can't physically get a better time

... using the same techniques the TAS does.

It's possible (although unlikely) that a new glitch/exploit could be discovered that allows for faster times.

ilitirit··on Molecule produced during fasting has anti-aging effect on vascular system
I'm not so sure. IF was in "fad" mode several years ago. The IF sub-reddit is already 6 years old. Now it just appears to be something that people are rediscovering because of posts (mainly on social media) about this type of research. There's nothing "new" in IF in terms of the approach to diet.

Here's an HN submission from 2012:

https://news.ycombinator.com/item?id=4341091

ilitirit··on Clicker Diet: Tracking Diet with Tally Counter
> reducing calories is literally the only way you will ever lose weight.

That is demonstrably false.

If weight Z = X intake + Y energy expenditure, then you can reduce Z by keeping X the same and increasing Y.

Obviously diet has much more of an impact than exercise, but it's not true to say that the only way to lose weight is to eat less.

ilitirit··on Civilization VI removes Red Shell ad-tracking software
Funnily enough (and not that it makes it OK) you didn't have to accept the agreement to play the game (just click "I don't agree" or whatever the option is). Not sure if they still continued harvesting data though...
ilitirit··on Nvidia Appears To Have A GPU Inventory Problem
I wonder if this has anything to do with ETH not being able to be mined on 3GB cards any more. I may be mistaken, but I recall several months back people with 3GB 1060s no longer being able to mine ETH because of the size of the DAG.

https://webcache.googleusercontent.com/search?q=cache:C6d8VK...

ilitirit··on Einstein's travel diaries reveal attitudes towards people he met in Asia
> “It would be a pity if these Chinese supplant all other races. For the likes of us the mere thought is unspeakably dreary.”

That's pretty much xenophobia in a nutshell.

ilitirit··on Adobe Photoshop 1.0.1 Source Code (2013)
Sometimes the code is perfectly easy to understand, but the reasons for the code may still be a complete mystery.

e.g. This is the kind of thing I find myself wondering very often while browsing our company's codebase:

"Why are we only appending the jurisdiction on this partner and not the others? Is this intentional or an oversight? Maybe the unit tests will tell me more..."

ilitirit··on The Myth of 'Learning Styles'
I've never really thought about "learning styles" in this way. For me, it has more to do with nurture than nature (i.e. culture, upbringing, environment etc) than something inherent. I recall a talk on "systems thinking" and how certain tribes in Africa (? - I don't recall exactly) fared very poorly on certain Western tests that required them to group certain objects together. It turns out that due to their culture they thought of things in terms of their roles in a system, rather than classifications that may seem more fundamental to us. e.g. We might group cooking utensils together, whereas they (and this is just an arbitrary example) would group the utensils, food and seeds together because their taxonomy works on a "higher" (or rather, different) level. From this, it seemed obvious to me that certain learning "styles" are better suited to developing a certain type of thinking.

So from a practical point of view, I don't think that it's a myth at all...

ilitirit··on Tesla issues strongest statement yet blaming driver for deadly crash
Given the facts, who/what else would be to blame?

This IMO has more to do with PR than anything else.

Well... marketing too. I've never felt comfortable with the term "auto pilot" as it is used in the context of Tesla's vehicles. This is potentially a finnicky topic, but I think there should be better standards and legislation around what can be reasonably marketed as "auto pilot".

ilitirit··on TextQL: Execute SQL Against CSV or TSV
I'm pretty sure many people have written or attempted to write similar tools at least once before. It's as simple as programmatically importing to an in-memory sqlite instance and then executing SQL queries.
ilitirit··on Tesla crash in September showed similarities to fatal Mountain View accident
> at only reducing 40% accidents

Unless I'm missing something, 40% is actually a good result (given what they're trying to measure).

However, I think the more important statistic would be regarding how many injuries/fatalities does it reduce vs cause. Are there any studies on this?

ilitirit··on Supertasks
Vsauce did a video on this topic.

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

ilitirit··on Firefox Product Roadmap
> Even I noticed that Chrome uses more RAM that FF

Reflects my experience. I use Firefox at work, Chrome at home. Chrome RAM usage is much higher than FF. Not that I really mind - I have more than enough RAM to support it. But it often leaves me wondering if some tab/plugin/extension is misbehaving, which in turn forces me to close all my tabs only to find that the memory use stays high and the number of Chrome processes doesn't decrease as expected. I'm considering switching back to Firefox at home now.

EDIT: OK, tested with Firefox now. Number of process doesn't decrease as I close tabs either, but memory use is still considerably higher than Chrome.

ilitirit··on Complete and Voluntary Starvation of 50 days
I started eating once a day about 2 months ago. Lost about 20kg. After a while you just stop getting as hungry as you usually would. Sometimes when I'm busy I actually forget to eat.
ilitirit··on Counterintuitive Properties of High Dimensional Space
There's a (sort of) intuitive way of understanding why things like these are possible without even seeing it visually.

How can you make two solid 2D squares occupy the space? They can't travel through each other, so...? Easy. Lift one of the squares into the 3rd Dimension, move it to the same X,Y coords, then drop it on the other (think of putting stacking 2 pieces of paper).

Similarly, you can have two 3D objects occupy the same space by "lifting" one into the 4th dimension, moving it to the same X,Y,Z coords as the other, and then "dropping it". You can "cheat" by thinking of the 4th dimension as time - one object travels through time, places itself at the same position of where the other object is, then returns. But as I said, that's "cheating".

ilitirit··on Are Monads a Waste of Time?
On the off chance that you know C# and Linq:

    // A Box that holds stuff
    public class BoxOfStuff<TStuff>
    {
        public TStuff Value { get; private set; }

        public BoxOfStuff(TStuff value)
        {
            Value = value;
        }
    }

    // Class that holds methods for working with Boxes of stuff
    public static class Ext
    {
        // Takes something and puts it in a box
        public static BoxOfStuff<TStuff> PutInABox<TStuff>(this TStuff thingToPutInTheBox)
        {
            return new BoxOfStuff<TStuff>(thingToPutInTheBox);
        }

        // Converts a Box containing one thing into a Box containing something else
        public static BoxOfStuff<TOtherStuff> ConvertBox<TStuff, TOtherStuff>(this BoxOfStuff<TStuff> theBoxItself, 
            Func<TStuff, BoxOfStuff<TOtherStuff>> functionThatConvertsTheBox)
        {
            return functionThatConvertsTheBox(theBoxItself.Value);
        }
    }

    // Class that holds a string value
    public class StringHolder
    {
        public string Value;
        
        public StringHolder(string value)
        {
            Value = value;
        }
        
        public override string ToString()
        {
            return Value;
        }
    }

    var result = new StringHolder("A random string").PutInABox()
        .ConvertBox(randomString => new Random((int)DateTime.Now.Ticks).Next().PutInABox()
                .ConvertBox(randomNumber => (Guid.NewGuid()).PutInABox()
                        .ConvertBox(guid => ($"{randomString}, {randomNumber}, {guid}").PutInABox())));
        
    Console.WriteLine(result);

    // Compare the above result to this:    
    public static class LinqExt
    {
        public static IEnumerable<T> ToEnumerable<T>(this T t)
        {
            return new List<T> { t };
        }
    }

    var linqResult = new StringHolder("A random string").ToEnumerable()
        .SelectMany(randomString => new Random((int)DateTime.Now.Ticks).Next().ToEnumerable()
                .SelectMany(randomNumber => Guid.NewGuid().ToEnumerable()
                        .SelectMany(guid => ($"{randomString}, {randomNumber}, {guid}").ToEnumerable())));
                
    Console.WriteLine(linqResult);
BoxOfStuff + PutInABox + ConvertBox = Monad.

This is analogous to:

IEnumerable + ToEnumerable (the Identity function) + SelectMany (the Bind function). To be honest, this is a fairly loose, non-rigorous definition even by programming standards, but if you've used LINQ before it should give you an idea of how useful Monads can be and how they can be used.

LINQ works the way it does because of Monads. In fact, if I were to add a Map function (Select) to BoxOfStuff and rename ConvertBox to SelectMany, I could use query syntax eg.

   var result = from thing in myBoxOfStuff
                select thing.ToString();
ilitirit··on A Reimplementation of Winamp 2.9 in HTML5 and JavaScript
I still use Winamp 2.95 to this day. It's one of the most reliable and practically useful pieces of software I run often.
ilitirit··on Billy Mitchell's current Donkey Kong score removed due to suspected emulator use
Note that the score was removed from the Donkey Kong Forum High Score List, not Twin Galaxies.
← PreviousPage 6 of 20Next →