HNHacker News
TopNewBestAskShowJobs

kris-s

620 karma · joined November 10, 2015

krisshamloo.com
submissionscomments
kris-s··on Advent of Swift
>The string processing is powerful, but inconvenient when you want to do things like indexing by offsets or ranges, due to Unicode semantics. (This is probably a good thing in general.)

This is being too generous to Swift's poorly designed String API. The author gets into it immediately after the quote with an Array<Character> workaround, regex issues, and later Substring pain. It's not a fatal flaw, a language backed by one of the richest companies in the world can have few fatal flaws, but AoC in particular shines a light on it.

I really like Swift as an application/games language but I think it unlikely it can ever escape that domain.

kris-s··on Current Software Engineers Have No Deep Knowledge (Jonathan Blow) [video]
In absolute terms the number of people with deep knowledge here is probably higher than it’s ever been. The ratio has changed, which is what I think he’s actually lamenting here. He mentions civil engineering; one thing I find myself often bringing up is that software engineering is a brand new discipline. The operating domain of softare is immense, maybe infinite. So I’m less curmudgeonly than Jon is here, we’ve got a barely century or so of software experience as a species, there’s gonna be slop.
kris-s··on Getting things done in small increments (2022)
If they are competing with each other such that neither are getting done are they really priorities?
kris-s··on Putting the "J" in the RPG, Part 3: Playing Final Fantasy VII
I would not have been as kind to FF7 as this author was. By any modern measure it is a bad game. The raw story material and the character design is fantastic. But the gameplay. The gameplay is so tedious the author couldn’t even continue without modifying the game.
kris-s··on Learning Jai via Advent of Code
Seems like Jonathan Blow, the creator of Jai, releases a game every decade or so. I wonder if the plan is to release his next game in a couple of years. Presumably it is written in this new language? Maybe the compiler will be released at the same time under the guise of “hey this is so production ready we have already shipped a game with it.”
kris-s··on Ask HN: Those making $0/month or less on side projects – Show and tell
My mobile game https://smoldungeon.com doesn't make me any money. Was very fun to make though
kris-s··on Rust concepts I wish I learned earlier
The author mentions the following:

    fn add(x: Option<i32>, y: Option<i32>) -> Option<i32> {
        if x.is_none() || y.is_none() {
            return None;
        }
        return Some(x.unwrap() + y.unwrap());
    }
    The above looks kind of clunky because of the none checks it needs to perform, and it also sucks that we have to extract values out of both options and construct a new option out of that. However, we can much better than this thanks to Option’s special properties! Here’s what we could do

    fn add(x: Option<i32>, y: Option<i32>) -> Option<i32> {
        x.zip(y).map(|(a, b)| a+b)
    }
Do folks really prefer the latter example? The first one is so clear to me and the second looks inscrutable.
kris-s··on Promotion of alternative social platforms policy
Is Elon Musk this century's Howard Hughes?
kris-s··on Isometric Pixel Art
I wrote a short guide for how I did some of the pixel art in Smol Dungeon. Hopefully I kept it approachable.

https://smoldungeon.com/pixel-art

kris-s··on Republicans Sue Google to Try to Force Spam into Your Inbox
I think that's how the Hey email service does it.
kris-s··on Goal: Pass all 4259065 tests in sqllogictest in 1 week
What a cool project, I bet they learned a ton doing this.
kris-s··on Speeding up this site by 50x (2014)
I run a few websites on a single Linode, they're quite snappy if you don't do too much. No fancy optimizations required, just keep it vanilla, you can make great websites with just modern HTML, JS, CSS: https://krisshamloo.com

I'm sure it's been posted to HN before, but I love this blog post about it: https://idlewords.com/talks/website_obesity.htm

kris-s··on “Code” 2nd Edition
One of my all-time favorite works of non-fiction. Essential reading for software engineers.
kris-s··on Pixel Art: Common Mistakes (2020)
I don't know if I would agree that the final scene is more readable - especially the treasure chest. I can't deny it looks much nicer though! I spent a lot of time tweaking the sprites in my game for readability. I touch on it here [1] but maybe I should do a full tutorial with intermediate steps.

https://smoldungeon.com/design

kris-s··on The death of the sit-up
It's still around in some places, CrossFit gyms still include sit-ups and GHD sit-ups in their programming. But CrossFit and ill-thought movements go hand in hand.
kris-s··on Deep learning is hitting a wall?
How many floppies to install Windows 9.93?
kris-s··on Deep learning is hitting a wall?
Thanks! Yeah it struggles with periodic functions that are wide. For example it successfully crosses zero with sin(PIxN/5) and delivers reasonable results for sin(PIxN/3). For your specific example you would probably need to provide something like N=1 to N=50.
kris-s··on Deep learning is hitting a wall?
how would you describe the pattern of the first one?
kris-s··on Deep learning is hitting a wall?
I wrote a little hobbyist AI project [1] with no neural networks at all and was delighted with how good the results were. Definitely think the field is ready to start incorporating some different approaches.

[1] https://littlefish.fish

Feel free to play around with it.

kris-s··on An unsolicited streaming app spec
These ideas extend well beyond the realm of streaming apps too - so much of the software I use day to day is shockingly bad. Far, far too much churn driven from ladder-climbing obsessed middle managers who want rewrites and redesigns and engagement to go up up up.
kris-s··on Ask HN: What is your “I don't care if this succeeds” project?
Oh thanks! I'll do that, I do not know anything about SEO.
kris-s··on Ask HN: What is your “I don't care if this succeeds” project?
I made a little dungeon crawler game that I needed to make to prove to myself I could actually ship a complete game, which has been a struggle for me.

https://smoldungeon.com

kris-s··on Simple Dungeon Map Generation
He's the Rusty roguelike king, I worked through this awesome book when I was learning Rust.

https://bfnightly.bracketproductions.com

kris-s··on Simple Dungeon Map Generation
That's an awesome article, I'll add a link to it.
kris-s··on A system in which soft robots “evolve” to walk or climb
Fabulous animations, I hope this means we're close to applying these genetic algorithm techniques to soft robots that we can actually build.
kris-s··on Ludum Dare 49 (Game jam)
If you've never tried programming a game I would highly recommend it. There are many aspects that make a game a really interesting challenge: input, rendering, sound, and managing large global mutable state. Ludum Dare is a good excuse to dip your toes in.
kris-s··on Apple explicitly asks employees to merge their personal and work accounts
This isn't true for me; I have a separate Apple ID for work. I was never explicitly told to use my personal one.
kris-s··on Deep reinforcement learning is a waste of time (2019)
What did you have in mind?
kris-s··on Deep reinforcement learning is a waste of time (2019)
> and allow genetic algorithms to evolve their own inputs and reward functions on their own

I've been playing with genetic algorithms for years now as a hobby and this type approach was a dead end for me, the GA entities would just "game the system" as it were and would min/max in surprising ways.

My latest genetic algorithm creation https://littlefish.fish has performed far better at pattern recognition than I expected. I really think they've got massive potential.

kris-s··on Maxwell’s Demon Continues to Startle Scientists
I wonder if Laplace’s demon knows about Maxwell’s.
Page 1 of 4Next →