Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I taught at a programming camp one summer, and my favourite example of this that I drove several kids crazy with was "above the line, below the line".

Given any input word, I would tell them whether it was above the line, or below the line (which corresponded to acceptable and unacceptable behaviour in camp-speak). I think only two kids figured it out on their own, and each time I challenged them to write a program to categorize words automatically.

I wonder if hacker news can figure it out :)

"Hacker" -> Above the line

"News" -> Above the line

"chrisweekly" -> Below the line

"functional" -> Above the line

"programming" -> Below the line



(Spoiler?)

I think it's called "above the line" "below the line" because the characters in each of the accepted words don't travel below the "character placement line" that runs along the bottom of every word. I've forgotten the "real name" for this line.

Thus,

  toothpaste -> below the line, because of "p"

  tooth -> above the line, no characters pass below it.
Generally, if the word contains a y,p,q,g, or j, then it's "below".

Right?

EDITS:

1: TIL the name for this property of a character is called a descender[1]. (And yet I still can't find the name for that blasted line.)

2: It's called a baseline[2], thanks taylorlunt

REFS:

[1] https://www.merriam-webster.com/dictionary/descender

[2] https://typedecon.com/blogs/type-glossary/baseline/


This is the right answer! I think it was made harder in the camp due to "above the line" and "below the line" already having semantic meaning in the context of the camp, most kids didn't expect that to literally be the answer.


yeah that makes sense, thanks for sharing it with us!

I'll likely use it to mystify kids someday soon.


That reminds me of “green glass door” and what you can and can’t take with you to magic land through the door.


The line is called a baseline.


Thanks :)


    let descenders = ['q','y','g','p','j'];
    let isBelow = (word) => descenders.some(d => word.includes(d));

    let tests = {
      "Hacker" : false,
      "News" : false,
      "chrisweekly" : true,
      "programming" : true,
    };
    
    for (const test in tests) {
      let pass = isBelow(test) == tests[test];
      console.log( pass ? `Passed for ${test}` : `Failed for ${test}` );
    }


Ding ding ding. You get extra camp tickets for adding tests :)


Rather depends what font the quizmaster is speaking in: https://graphicdesign.stackexchange.com/questions/71807/what...


Ha, yes, and what language. My example won’t work for ŷ and any others like it.


Just a guess:

    data TheLine = Above | Below

    categoriseWord :: String -> TheLine
    categoriseWord s
      | length s <= 10 = Above
      | otherwise      = Below
There's not a lot to go on, though.


There is a similar game that goes like "The king does not like tea but he does like coffee". The you can ask questions like "Does he like cookies?" (answer: yes), "Does he like cats?" (answer: no)


Curious that the way we play these games is “race to the answer” in fewest tests, and as soon as someone else gets it, the game is over and spoiled for anyone who didn’t.

Is there a good way to play to train for “most confidence before answering” without making it a drudge of endless tests and humhawing?

Making each question a more powerful test would be good, but that’s not what racing to the answer encourages, that encourages guessing the teacher’s password.

What about tests are free, first to answer wins, but a wrong answer or two disqualifies you completely?


Words go below the line iff they contain the same letter twice in a row


Been -> Above the line

Fuzzy -> Below the line

Weeds -> Above the line


In college a friend had about 10 of us dumbfounded for an hour as we tried to figure out what "The land of Nodd" was.

The land of Nodd has floors, but no ceiling. It has grass but no lawn. It has no animals but there are teeth. Etc.

The game is we asked him questions about whether it has something or does not, and we had to figure out what "The land of Nodd" was :P


I'm guessing Nodd has a lot of bookkeepers!


I'm taking this comment as evidence that I've succeeded in figuring it out.


We used to play a game in summer camp where one had two sticks and could hand them to the next person 'crossed' or 'uncrossed' declaring as such. The key was it was the persons legs, not the sticks, which determined if one was passing the sticks 'crossed' or 'uncrossed'.


Current list of words is consistent with "has an even number of letters".

What about "Hacks"? It uses only letters found in accepted words, but should be rejected because of the odd number of letters.


Check for odd or even string length?

  "Above the line" if len(s) % 2 == 0 else "Below the line"




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: