HNHacker News
TopNewBestAskShowJobs

bhrgunatha

1,346 karma · joined April 21, 2009

submissionscomments
bhrgunatha··on Numpy: Plan for dropping Python 2.7 support
I wonder whether Python itself will improve faster when the development team no longer needs to maintain 2 versions or whether the burden on them will just reduce somewhat.
bhrgunatha··on RSS: there's nothing better
It is a pain - I've found 3 formats for users, channels and playlists:

    https://www.youtube.com/feeds/videos.xml?user=<user name from url>

    https://www.youtube.com/feeds/videos.xml?playlist_id=<id from url>

    https://www.youtube.com/feeds/videos.xml?channel_id=<id from url>
I wonder if there are more?
bhrgunatha··on A collection of non-standard punctuation marks
Right, the symbols are SVG but not rest of the text.
bhrgunatha··on .NET core spies on users by default
> Lots of FUD as usual with these topics.

> It's definitely nothing out of the ordinary and is common practice among many tools and apps you already use.

Also as usual it's opt-out and NOT opt-in. People get riled because (usually)

a) built in telemetry is almost always an unexpected and unannounced change - only to be discovered later.

b) opt-in is the only approach that leaves your trust in tact - everyone uses opt-out because they know the majority of users people will not choose to opt in given a choice.

bhrgunatha··on A collection of non-standard punctuation marks
There is ‽ - https://en.wikipedia.org/wiki/Interrobang

> this site doesn't let you copy text

Being generous here, presumably people still pull this kind of ridiculous crap to prevent uninformed users from "stealing" their IP. I guess they must be smart enough to know that if it's rendering as text, anyone can access and copy it.

bhrgunatha··on ‘Let's Make a Deal’ host Monty Hall has died
> Even when given explanations, simulations, and formal mathematical proofs, many people still do not accept that switching is the best strategy (vos Savant 1991a). Paul Erdős, one of the most prolific mathematicians in history, remained unconvinced until he was shown a computer simulation demonstrating the predicted result (Vazsonyi 1999).

It's such a deceptively simple problem that's so easy to get wrong. I introduced it to my boss and he just wouldn't believe me when I told him the answer. He spent about 10 minutes formulating a simulation in Excel in order to convince himself.

bhrgunatha··on New theory why languages don’t all have the same number of terms for colors
In the UK it's Amber. I can't remember ever hearing yellow.
bhrgunatha··on Tree Style Tabs Extension Ported to Firefox 57
It's not just about being able to select what to download, that's a minimal part of what makes DTA so useful.

Does it allow you to manage your downloads though - like supporting multi-source downloads, pausing and re-starting, exporting/ importing lists, prioritise, re-order, limit speed, integrating with the save dialog and menus ...

DownThemAll is the one extension that might force me to abandon firefox or to stick with an ESR release and not upgrade.

bhrgunatha··on Harry Dean Stanton has died
Likewise in my circle of friends we used to quote this movie a lot.

But later it was elevated to an unassailable classic due to the ridiculous over-dubbing when it was shown on TV, replacing all the use of mother-fucker with melon-farmer.

bhrgunatha··on What Monoids teach us about software
It's saying that the operation can be made parallel.

Applying an operation to a total workload is identical to:

1) Split the total workload into smaller workloads.

2) Apply the operation to each smaller workload.

3) Apply the operation to the results from step 2.

Each smaller workload in step 2 can be run in parallel.

While that may seem obvious for adding numbers or money it may be less obvious when you have different operations for example a method in an OO class hierarchy.

bhrgunatha··on Magnitude-8+ Earthquake, 87km SW of Pijijiapan, Mexico
USGS (and most reports use the moment magnitude scale - https://en.wikipedia.org/wiki/Moment_magnitude_scale :

Each point is 10 ^ 1.5 (about 31)

Every 2 points is 100

The Richter scale is almost never used now but that'd where the factor of 10 per point comes from.

bhrgunatha··on Show HN: Make Medium Readable Again
Website readability in general has degraded seriously in recent years. Flat buttons/links that can't be discerned as clickable, low contrast text, the resurgence of mystery meat navigation and plenty more annoyances I don't even remember.

Luckily we have better tools these days to combat them. The fact that firefox has a built in reader mode is indicative of how user hostile web readability is these days.

bhrgunatha··on Designing a Tree Diff Algorithm Using Dynamic Programming and A*
> When I first heard the problem, it sounded pretty easy and I thought I’d be done within a few days, but I discovered a number of catches after starting and it ended up taking 5 weeks

It's really refreshing to hear about this type of real world estimation error that reflects so well the problem in software of making estimates with so many unknowns.

bhrgunatha··on Epistle 3
Not sure if you've seen this or not but it sounds really plausible to me.

Why valve will never release Half Life 3 - https://www.youtube.com/watch?v=50lSIaSR3zc

bhrgunatha··on The Lost Art of Stealing Fruit
I guess the modern equivalent is supermarkets letting people take their unsold or out of date food?
bhrgunatha··on An Intro to Compilers
Compiler/transpiler - same difference.

I think they've gone out of fashion now, but when I learned about compilers we were introduced to T-diagrams, sometimes called tombstone or bratman diagrams and shown how to bootstrap a compiler for a high level language from scratch [1].

Torben Mogensen's Basics of Compiler Design [2] - Chapter 13 is devoted to bootstrapping a compiler, which introduces them.

[1] scratch meaning a computer (with relevant hardware) with a CPU with it's machine code instructions and some way to make files containing those instructions. You can do this even without assembler, that's the first step. Of course no-one would do this now, but it's a necessary step developing the first high level languages and compilers.

[2] http://www.diku.dk/hjemmesider/ansatte/torbenm/Basics/

bhrgunatha··on Show HN: Using functions to construct Regex in Python
> compared to writing raw regexes in string form ...

> Emacs's nasty regex syntax

It's also case-sensitive too. Writing regex by hand when there is a mixture of case sensitivity to recognise is not at all pleasant.

bhrgunatha··on What the heck is a parser-combinator?
Or watch on youtube: https://www.youtube.com/watch?v=RDalzi7mhdY

No need to create an account or login

bhrgunatha··on The Benefits of Talking to Yourself
Writing things down - or sketching or using mind-maps (not software but actually drawing your own manually) - seems to have an amazing effect on the brain.

We haven't been writing long (in evolutionary terms) so I wonder why that is?

bhrgunatha··on My Arch Linux Setup with Plasma 5
To be fair KDE4 _was_ a disaster when it was released but in time it came to be as stable and usable as the much loved KDE3. The path to plasma was also somewhat rocky (but nowhere near as bad as the KDE3 - KDE4 transition).

I used to enjoy using KDE but I feel they lost their way and are overly attracted by "shiny new things" like workspaces, activities, or semantic desktop - virtually everything being dependent on strigi then akonadi then nepomuk then baloo or ... The real bugbear is that every time they ditch everything for a new metaphor - so much of the previously working and reliable software is also ditched or obsolete.

It doesn't suit my needs to have to keep re-configuring my computer and software and workflow so I stopped using it.

I do think it's great and valuable that it's there as an option though.

bhrgunatha··on Show HN: “Statements and State”, the next chapter of my book on interpreters
I like this book a lot - especially making it available to read free in HTML. It's good to see practical information about parsing and grammar rather than plainly theoretical - although there's room and a for need both.

Another similar read is Vidar Hokstad's blog series - Writing a compiler in Ruby [1] which was first submitted here 9 years ago! [2]

[1] http://hokstad.com/compiler

[2] https://news.ycombinator.com/item?id=319337

bhrgunatha··on GNU Smalltalk Koans
Reader view is such an invaluable feature for me.

The icon sometimes doesn't appear in the address bar though (apparently because Firefox is unable to identify where the text content is in the page.)

I've also found the extension - Open in Reader View [1] to be useful for those situations.

[1] http://firefox.add0n.com/reader-view.html - Firefox, Chrome and Opera

bhrgunatha··on The new ASP.NET Core 2.0 packages can no longer be used on .NET Desktop
I understand what .Net standard and .Net core are but I think they need a better strategy for their nomenclature that using .Net in the name of every runtime, platform and set of libraries.
bhrgunatha··on Stop Guessing Languages Based on IP Address
Google stopped respecting 'ncr' quite a long time ago. If it does still work for you it's a lucky coincidence. I've used ncr previously but it stopped working.
bhrgunatha··on Stop Guessing Languages Based on IP Address
I've been complaining about this for a long time now.

I wrote a small greasemonkey script to add hl=en to all except a select few google locations. They are the most egregious. Unfortunately for us the industry has chosen to go with IP address determines language and it's getting more and more common.

I DO have accept language configured in my browser and I also DO understand that statistically many people's browsers are mis-configured. NO. I'm not leaving my browsers logged in to every site in the internet.

We'll forever be tilting at windmills.

bhrgunatha··on P vs. NP
To be clear I'm not talking about how useful asymptotic analysis and big O notation are in general, I'm talking specifically about the case if we eventually do prove P = NP.

Internet lore and popular media then assume that immediately for example all encryption will be trivially broken. Mathematically it may be true because then all NP problems would be known to be polynomial, but there's still the issue of the practical steps involved factorising a huge number which may have enormous constants or very large exponents. Or if it turns out we can reduce it to some other known polynomial problem, there's still the actual transformation which itself may be polynomial with large constants or exponents.

bhrgunatha··on P vs. NP
Yes, this always confuses me. Why the constants are swept under teh carpet for real world, practical applications. From the same article.

"It is also possible that a proof would not lead directly to efficient methods, perhaps if the proof is non-constructive, or the size of the bounding polynomial is too big to be efficient in practice."

Given the long standing nature of the problem, my guess is that some new techniques or insights will be required to solve it one way or the other. Those may well give clues to solving NP/NP-Complete problems efficiently.

Until someone actually does it though it's still just speculation.

bhrgunatha··on The Origin of CAR and CDR in Lisp (2005)
Instead of (f)irst/(r)est we could use (h)ead _or_ (f)irst and (r)est. Then the pronunciation is just exactly as it is spelled - https://www.youtube.com/watch?v=spefM2OjKp4
bhrgunatha··on A practical introduction to functional programming (2013)
You decompose the complex task into separate other tasks and compose them together the same way that you would in any other paradigm. You wouldn't expect to express a complex task in a single line in an OO program for example.

documents = filter(pdf, folder)

summaries = map(summarise_document, documents)

Is pretty clear despite summarising a document being a complex task.

bhrgunatha··on Tsunami warning issued after magnitude 7.9 quake hits east of Papua New Guinea
The factor changes for a 1 point increase are different.

Richter 10 (to the power 1)

Moment magnitude about 32 (to the power 1.5)

For an increase of 2:

Richter exactly 100

Moment magnitude exactly 1000

← PreviousPage 6 of 14Next →