159 comments

[ 3.6 ms ] story [ 204 ms ] thread
That is cool - it is nice and simple, but fun. The code is clearly from a beginner, but the saved game bit shows that she is a clever beginner - such a pragmatic way to continue a game. I hope she keeps learning and building more.
Great game! I would love a hint function though, as I honestly got stuck.
Or even a "give up" button because I'm definitely stumped
Once you get it, you are going to erupt!
I got completely stuck, tries various word solvers, but they seemed to be for cross words or anagrams, but they were no help. But an actual dictionary / word list unlocked it. Not sure if using a dictionary goes against the spirit of the game or is expected. Without it it seems incredibly difficult.
Cool! 10 guesses got me there. Thought it was gonna be impossible.
Took me 13 guesses but it is a great game for a few reasons:

- It can work for multiple age ranges by varying word lengths - It has good replay-ability - It can be adapted for offline play - It can be adapted for learners of new languages as well

I like it, pretty simple concept, good execution. I have to admit though, narrowing down a word purely by alphabetization can take a good while. Perhaps letting the player know the length of the target word would help.

Congrats to your grandma for making a game!

It doesn’t work on phone, sigh
Looks like the developer is aware there may be limitations.

> <!-- When the player pressed Enter it should start the guessWord. Need to test on phone -→

Hopefully a new version will be released free of charge for current customers.

Oh, there is a readable JavaScript inside!
FWIW, it worked fine on my phone. Brave on an iPhone
Yep, likely my iPhone to blame
Is this a bug? https://i.imgur.com/b5HqHeA.png

Vodka should not be below voice.

Is it always the same word?

My word is between Vodka and Vomit :D

It’s like wordle: different word every day and everyone gets it. At least that’s what the text says once you get it.
(comment deleted)
At least for the next 13 days, when gma will learn about null pointers
Did you guess a word which was already excluded? Maybe the arrangement of words assumed only "valid" guesses
It means you guessed "vodka" after she already told you the word was after "voice"
I hope Grandma has some analytics hooked up to see all the traffic coming in!

A small bug report: the "Share score" button on macOS Safari doesn't offer "copy" as an option for some reason. The same functionality on guess the game[0] has the same limitation, but it also copies to the clipboard automatically. Wordle[1] seems to just copy to the clipboard only.

[0]: https://guessthe.game

[1]: https://www.nytimes.com/games/wordle/index.html

Grandma is a Cloudflare Analytics user, apparently.
Good gameplay! The one strong suggestion I have is to limit the word list to a category that uses common words. I had to resort to look at the word list dictionary in the console to see the possible words, and many of the words were extremely obscure.

I would come up with categories of increasing difficulty. "Colors", "Advanced Colors", "Common Fruit", "All Fruit", etc.

The game mechanic is great and worked flawlessly though!

Reading the code is a joy. I love seeing different approaches to what we all take as givens, such as design.css rather than style.css, or the usage of an `else if (1 == 1)` compared to `else` or even `else if (true)`.

(So I guess, thanks for not teaching her about bundlers and minifiers yet :))

One reason programmers do this is so that they can make a one character change, e.g. "else if (1 === 1)" -> "else if (1 === 2)" in order to change the logic there. For C programers you see a lot of '#if 0' '#if 1' for this same purpose. Though, given that it's used everywhere, I'm not sure if it's really for that purpose.
I’m a big fan of tacking on “&& false” or “|| true” as well.
[flagged]
spoiler warning! don't look at the source if you're going to play the game because the number of possible valid words is short
I see 279496 valid words in dictionary.js

…ooooh I see the 20 secretWords now

I don’t understand why any of that indicates that a 70 year old couldn’t have created this, unless you think 70 year old people aren’t capable of doing that.
My dad is 64 and he can still use AutoCAD like he's playing piano
The age isn't really the inconsistency, it's the "only just learning to code" aspect. My first ever webpage was certainly not hosted behind Cloudflare. (I'd also expect beginner resources to point to something like GitHub Pages instead)
> About the game: somewhat fun but if you don't know the word, that's it. No really any way to figure out in a rewarding way.

What does this mean? You could say the same thing about Wordle.

I guessed many words I didn't know on Wordle (not a native English speaker), if you are able to reduce enough the letters search space there's going to be only a few options that e.g. make sense phonetically.
I actually misread the original comment but I guess my question is still somewhat relevant so leaving it as it is. You're right that it's easier to just bruteforce it in Wordle.
Pasting the <script src one-liner code for page analytics was one of the first things I did when coding my first angelfire website as a 10 year old. I loved seeing the graph of how many daily visitors I got.
> Not to be negative or anything but [pure shade]

I'm gonna bet that my mom has had a website since before you were born*. She was taking fortran classes in the 60s. Your ageist attitude is pretty gross. So what if she had help? Another bet, you can't program without the help of online resources and/or a chatbot either.

* given the dates on your resume, there's a very good chance I'm correct in this

you are being just as rude as the other person, if not more, buddy. There is a much better and constructive way to make this point. Also, the title says that she is "learning to code" so its not unreasonable to say that she probably isn't handling the website stuff... Also, the commenter is making a conjecture about the veracity of OP, not the mother per se.
I am old myself. It is not ability to learn with age that is suspicious it is wanting to share it like this and it would be a clever marketing move.

I will learn new things until the day I can't. I am currently learning the Stan language but I am not going to write a medium article "What happens when an old man attempts to learn Stan?"

I bet you could write that article, regardless of programming experience, and tell a compelling story. Different people share different parts of themselves online, and I think that's okay.
What a spiteful comment over a little skepticism
(comment deleted)
I'd characterize the original comment as a cynical accusation of shilling, so I'm quite curious what you read as "spite" in mine. Must I point out that I, too, use external resources whilst programming?
> > Not to be negative or anything but [absolutely justified skepticism based on how much various publicity stunts have been done]

Your comment is also much much ruder than the one you're replying to.

Aside from the other comments, it could be the case she's using a deployment tool that does this for her.
It's subjective how rewarding it is but you can definitely guess the word if you know, well, words, by doing a binary search and narrowing down the first letters. I have an uneasy relationship with puzzles and I'm not a native speaker but this to me is about as fun and about as infuriating as Wordle or Semantle (try the latter if you didn't already!)
(comment deleted)
There is some bug in the sorting, because it sorted “vol” after “volatile” for me. It seems to depend on some previous state, though, because I couldn’t reproduce it in a new window.

Edit: See also https://news.ycombinator.com/item?id=41217457.

It seems the previous guess is always placed either one up or one down from the entry box. So if you're guessing "V" words, then type "apple", then "apple" will show after "vodka". So the list is not getting re-alphabatized.
Right. My word was before "wizard," and later I guessed "yesterday," which is after wizard. It put yesterday adjacent to the entry box, before wizard. Same is true for words before the word. Basically, if I make bad guesses, it doesn't list them in alpha order.
I had a similar issue. Void sorted before Vogue. Breaks the game totally as far as I can tell.
It might not be sorted intentionally as part of the challenge of the game.
Great game! looks nice too...

I got reeeealy close (and then asked an llm....)

time to LLM a binary search

  import requests
  url = 'https://grandmasword.com/dictionary.js'
  response = requests.get(url)
  lines = response.text.split('\n')[2:]
  exec('\n'.join(lines))
  def binary_search(dictionary):
    while len(dictionary) > 1:
        mid_index = len(dictionary) // 2
        mid_word = dictionary[mid_index]
        print(f"Guess this middle word: {mid_word}")
        user_input = input("Did grandma say her word is before or after? (type b or a)").strip().lower()
        dictionary = dictionary[:mid_index] if user_input == "b" else dictionary[mid_index + 1:]
    print(f"Grannys word: {dictionary[0]}" if dictionary else "No words left in the dictionary.")
  binary_search(dictionary)
Solved in 18 guesses! Share score Thank you for visiting my website. There'll be a new word everyday just like Wordle. Kind regards, Eleanor
I mean that's literally how to play this game whether you intend to or not
I thought my manual binary search off the top of my head in 16 guesses was probably poor but if it beats a coded version, I'm happier now lol
Classic LLM hijinks or hacker goofing off on HN? Either might throw `exec('\n'.join(lines))` in a script running on a publicly downloaded file rather than parsing it more directly.
Nevertheless, it is somewhat curious that "dictionary.js" is nearly valid python.
So you didn't want to have fun playing the game, but also didn't want to have fun coding a solver? I understand the former, but not the latter... :D
Going from knowing exactly what I want, to it materializing from just from a 60 second conversation in the sidebar of my browser, does give me a bit of a buzz
Fair enough! But I am curious, was it you or the LLM that decided to exec a .js file as python?
SPOILER

view-source gives away the answer for the next 20 days....

It's okay, according to the source comments the only player is her friend Caroline
This game is somehow so compelling
In the spirit of helping a fellow programmer debug some things:

If you guess a word that isn’t in the dictionary, the text box looks like it’s cleared but my phone’s (iPhone) keyboard’s autocomplete either didn’t pick that up or there’s still some hidden content in the box.

It would be nice if the list was always sorted in totality.

This was fun. Good job, Eleanor!
I read the domain name as Grandma Sword. Maybe her next project :)
A refreshing new fantasy RPG.
the quest for perfect length yarn
My first entered word was "sword" so I read it same as you
I read this in Sean Connery’s voice.
Very cool.

My own 74 year old surviving parent would never be able to get them selves to even try, as they have spent most of their lives telling reiterating a mantra about how little they know about technology.

It has been a guiding principle of mine to never do that with anything, after seeing the effect it has had on her.

My mom is the same way. She’s really capable and smart, but she will also stop herself from plugging something in because she’s unsure.

I convinced her that she can figure out any remote and they are designed to be figured out. I told her at most there’s gonna be 5 buttons she doesn’t understand and it won’t break anything to hit them. Most of the buttons are numbers or volume and channel up down, power.

She got that. When her mom was sick and had different tvs because of different circumstances my mom would be like, “I did figure out the remote tho and was able to get the television working.”

I was with my 3 year old niece the other day and she turned on the receiver and then the television and I said , “wow, I’m impressed you figured that out.” And she said , “yeah when grandma watches me she doesn’t know how”. . .

Ever since I was a little kid, teaching the other little kids how to do math, I’ve believed that most people who think they aren’t able to do something aren’t able to do it because they think they can’t.

And I tell myself that every day as I try to learn guitar in my 40’s.

This website was likely not made by a 70 year old grandma judging by how it was promoted on reddit.

https://www.reddit.com/r/programming/comments/1enuhw5/my_70_...

https://www.reddit.com/user/Ruth_Ellaer

https://www.reddit.com/user/puzzledpenguins

(comment deleted)
If that's the case then what's the endgame of this promotion? Strange.
Testing the waters, I guess.

"it's my birthday today [AI generated image of Grandma with birthday cake]" is a viable business model on Facebook these days: https://www.404media.co/where-facebooks-ai-slop-comes-from/

If they get enough clicks they could put profitable ads on the page, or even sell it (like what happened with Wordle).

Go viral and show ads?

Get the chatter going, get "press", clicks, visitors and players, then potentially ads, or selling the site (for someone else to put even more ads on it), or using it as marketing reference (I made a game viral by lying about it).

Wordle sold for $1+ million. An average word game with a unique hook like "my grandma made it" is well positioned to sell or at least attract a lot of viral traffic.

Anyway, the grandma story has been exposed as fake.

The source fits the pattern of something generated by LLM and even includes comments that were probably part of the prompt.

Doesn't anyone else remember being a beginner? This isn't something I would have made. It has too many extra little nuances. The dictionary is a big clue.

It’s called learned helplessness and is a good indicator for pessimism. There is a book I enjoyed that discusses the issue in depth, called: Learned Optimism, by Martin Seligman. The second half of the book is about how to become less of a pessimist, by addressing learned helplessness.
Would adding an indicator of how many letters I've gotten correct / "locked in" be fun? I don't know if I'm supposed to be trying a new 2nd or 3rd letter after V.
"voi-" was sorted before "vog-" by the way!
I found Grandma's Word in 25 guesses

https://grandmasword.com

It was volcano but I only discovered it after finding that Android autocorrect can suggest a word for me.

spoiler alert -- no need to share the answer, it takes the fun away for others
Hopefully they just don't realize that the word is the same for everyone each day.
I was just relieved when it wasn't vulva