Algorithms + Data Structures = Programs - Episode 209: Scrabble, Cribbage & More! (Board Games Part 2)

Episode Date: November 22, 2024

In this episode, Conor and Ben chat about their favorite board games (again).Link to Episode 209 on WebsiteDiscuss this episode, leave a comment, or ask a question (on GitHub)TwitterADSP: The PodcastC...onor HoekstraBen DeaneShow NotesDate Recorded: 2024-11-12Date Released: 2024-11-22PaleovetWingspanJaipurSnake & LaddersTroubleScrabbleMonopolySuper Puzzle Fighter II TurboThe Stunning Rise of Scrabble's Strongest NationQuackleCribbageElixir LanguageQBasicYahtzeeIntro Song InfoMiss You by Sarah Jansen https://soundcloud.com/sarahjansenmusicCreative Commons — Attribution 3.0 Unported — CC BY 3.0Free Download / Stream: http://bit.ly/l-miss-youMusic promoted by Audio Library https://youtu.be/iYYxnasvfx8

Transcript
Discussion (0)
Starting point is 00:00:00 tried to figure out, you know, for loops, if statements and stuff. And then I was like, wait a second, like with these like couple tools, you could do, you could do anything. And then like the next two to three days, like disappeared. And I wrote this like 3000 line poker simulation. Cause that cribbage scoring is very interesting. Algorithmically. It's, it's one of those things that I periodically go back to
Starting point is 00:00:24 as sort of a coding practice coding exercises welcome to adsp the podcast episode 209 recorded on november 12th 2024 my name is connor and today with my co-host Ben, we chat about board games once again. We talk about Scrabble, Cribbage, the games we programmed when getting into programming, and more. Let's put a bow on the board games, and we'll just call this board games. Because you only mentioned one. Other top favorites of yours? Oh, let's see. What have I played? Oh, I really liked Paleo Vet.
Starting point is 00:01:09 Paleo Vet? Paleo Vet was a game I played with some friends lately. Yes, you are a veterinarian and you are taking care of dinosaurs. And every turn, there are five dinosaurs in the middle of the table, available to tranquilize and bring back to your veterinary practice. And once they're in your practice, you are healing them. Each dinosaur has some icons on its card to say what it requires to be healed. Maybe an antiviral, maybe antibiotic, maybe surgery, something like that nature, right?
Starting point is 00:01:44 There are different things you can do. And you roll dice, and they're not numbered dice, they're dice with icons on them every turn to figure out what you can do that turn. The dice have icons corresponding to the treatment icons. And the goal is, of course, to bring dinosaurs into your practice and heal them and then release them. The wrinkle
Starting point is 00:02:05 is that um dinosaurs aren't very friendly and um you while they're in your practice basically they are they are tranquilized they're asleep while you're healing them but their sleep counter is ticking down every turn um when they wake up they break out and run away if they are carnivores first of all they eat another dinosaur and then they run away so but then so so far this sounds like why all bad right but but then then you start to layer on the things like um extra points for achieving uh sets of dinosaurs. Like you can specialize in healing carnivores and that gives you like extra powers and extra points perhaps, or, you know, things, things of that nature. And, and the dinosaurs, and here I'm aware I'm using dinosaur in a loose term. So I think any large or not necessarily large,
Starting point is 00:03:01 but basically anything in the sort of reptile family from 65 plus million years ago counts as a dinosaur. So, you know, we can argue about pterosaurs and ichthyosaurs and things like that. But these are
Starting point is 00:03:17 classic dinosaurs. And it's just a lot of fun. It seems like another good game where it's a good blend of strategy and luck and choice over which path path to take is this a fun game i guess i've never heard of it yeah i found it at my local board game store i had not heard of it i haven't really seen it reviewed anywhere online i picked it up because i thought it was a good thematically good and it turned out to be a really fun game yeah so. So yeah, it's called Paleo Vet. Interesting.
Starting point is 00:03:47 Any other last minute pitches? In terms of themes, I think I mentioned the word wingspan is my partner and I's favorite game. Oh, yes. Although we haven't played it recently. They call it a bit of a point salad game because there's a lot going on. It's definitely not one of those two minutes to explain. It takes a couple rounds to get under it.
Starting point is 00:04:04 But as avid birders we and we'll go away on a trip and we'll come back and then we'll be like oh yeah now we've seen that bird um you know nice which is uh what it was definitely when we were in scandinavia though we saw a couple birds and then we came back and we were like oh even though we don't like that card herons and and things like that yeah for a two-player game, Jaipur is a good one. I think you told me about this game at one point. Is it the card-based one? It is, yes. It's Middle Eastern Marketplace, is the theme of the game. And you are buying various goods. And it's only a two player game, but it is a very good two player game.
Starting point is 00:04:51 One of the mechanics now I've got to remember is you basically get more points for being the first to buy certain goods. So, you know, there's, I forget the goods, but there's like spices and leather and maybe some other things. But basically if you're the first to buy a good, you get the sort of four point token and then the next person to buy can only get the three point token. So there's a, there's a sort of mechanic like that. I'm not sure I'm getting exactly right, but it's like that. And then there are, and then there are camels you can choose.
Starting point is 00:05:18 And whenever I play with my son, he can't resist whenever there's camels on our face, like, because basically you can choose to like corner the market in camels and take all of the camels instead of buying something, you know, and the camels on offer. Because basically you can choose to corner the market in camels and take all of the camels instead of buying something. And the camels might build up over a few turns until it becomes very attractive because, of course, you get points for having the largest camel herd. Yeah, he's learning about supply and demand. Yeah.
Starting point is 00:05:40 So that's a fun one. Anything to avoid, you know, once you have kids, board games become a different sort of thing. And mostly because you want to avoid, you know, when you're starting out teaching your kids, the games are really simple. Like Candyland, right? Candyland doesn't even involve a dice i think uh it's you move by colors you move by yeah you turn over cards and the color on the card is that is the next color space you move to on the on the twisting right path that's okay it's not a bad game you know at least in terms of little kids games
Starting point is 00:06:25 but snakes and ladders or shoots and ladders uh we call it snakes and ladders in the uk is one of the worst games ever invented it's up there with monopoly as one of the worst games uh for two reasons one the i mean the heavily moralistic background is not good but but as a race game snakes and ladders requires a exact count to finish and you know you can play it for five minutes and be nearly finished and you can still be nearly finished 20 minutes later right it is that kind of game. It is just painful. And in the end, you're just, because it's random every time, and you must get in by exact count. In a way, it's worse than Monopoly.
Starting point is 00:07:14 At least with Monopoly, at a certain point, you can just decide to play to lose. You just be like, sure, I'll trade you so you have the whole set of these things. Because, you know, we've been playing for an hour, and I just want the game to end. Right. have the whole set of these things because you know we've been playing for an hour and i just want the game to end right should i ask what the moral i don't even know what the moral uh problematic background oh i forget but basically you know the game right snakes and ladders so the idea is that you know good god-fearing i, children advance and children who do things which are questionable in the eyes of whatever morality was around in 1800s when it was invented. I don't know. They do not advance. It's that sort of game. I didn't realize there was any...
Starting point is 00:08:01 Yeah. So, if you... I never really played those games uh but you probably have you heard of the game trouble yes yeah that's another exact count yeah yeah like I think so my mother absolutely loves that game is that the pop-o-matic one exactly yeah that's done with the popper yeah I think it's actually got an alternative name and it might be like something like that you know you pop something where you pop the dice and you've got four people you need to get from home to go around the board once and then in. And I think the only decision you can make, or there's two decisions. One is if you have multiple pieces out, which one to move. Which piece to play, yeah.
Starting point is 00:08:40 Which is not nothing. And then the other one. It's really the only thing that could be called strategy. But I think if you get a six, you can, that's the other option. You can bring someone out. You must get a six to start. Yeah. Six, six, you can bring someone out.
Starting point is 00:08:57 Or if you have a person out, you cannot take someone out and, and move six. But anyways, almost completely luck and i would go i would pull my hair out so much just being like and and uh anyway so yes i feel your frustration i because that game is just i would always when i remember being a kid i was i would like act out and try and like make it fun because i was like this game is boring as hell so like the only thing that's going to make this fun is like someone starts pretending like this is the most important thing being like now my person went back home uh whereas a game like scrabble is actually yeah very fun well monopoly monopoly is a bad game right um because it's it's what i've heard called
Starting point is 00:09:41 among other things it's you know also besides the fact that it glorifies extreme capitalism um thinking property rent seeking yes it's a 51 percent game right which is how i've heard it called it's like like once you get slightly ahead it is there's a positive feedback loop right so once you get the idea of the's a positive feedback loop, right? So once you get the idea behind the 51% game, of course, if one person's 51%, then they run away with the win. Which, you know, Monopoly has random elements. So it's not totally true of Monopoly, but it's basically true. It's kind of fascinating, actually.
Starting point is 00:10:23 I think I saw online. So i obviously have a background in video games as you know a lot of video games fight against that kind of 51 game and there's a kind of game which is um exemplified by one of the first games i know uh is um super puzzle fighter to turbo extreme was it anyway it's one of these games where imagine competitive Tetris, right? But not Tetris. It's the one where you're not fitting the blocks in. You're just letting the blocks fall on top of each other in different colors. And when different color blocks meet, they merge into larger color blocks.
Starting point is 00:11:01 And then you can explode those larger color blocks and send things over to your to your opponent to deal with okay okay so it's it's like po po or a game of that nature right it's one of these games and it's head-to-head two players um it has a very interesting property that being about to win looks the same as being about to lose it's it's a it's not a 51 game it's a it's a sort of continual comeback game because if i send you a lot of material yes it fills up your side of the screen so it's a problem for you to deal with but it gives you a huge opportunity to send a bunch of stuff back to me right so it works both ways interesting so it's like is it not a is that does that involve like bluffing kind of of or is that it's a it's an arcade game right so so you're things are
Starting point is 00:11:54 continually dropping sometimes you're getting fuses which set off different color blocks right and the larger so you might if a two by say you get a two by two of reds they fuse together into a larger gem in this game right and say you get a two by three it would fuse into an even larger gem or three by three even larger right and the larger the gem gets the sort of geometrically more powerful it gets right so you send over more stuff for large gems comparatively but every character uh this game this this game i'm thinking of had a had a sort of street fighter character selection so every character you can select the street fighter to be your combatant had a different pattern of colors they would send over to your opponent
Starting point is 00:12:44 when you got you know a certain explosion of gems you would send over to your opponent when you got, you know, a certain explosion of gems. You would send over a dozen gems. The pattern they get sent depends on which character you picked. Interesting. So what's the risk at the end of sending, you know, you're close to sending something over, but the risk is that they'll be able to do something with that? Yeah, exactly. You've just sent a bunch of gems.
Starting point is 00:13:04 They are going to fall on whatever gems your opponent already has. They're going to fuse together into larger gems, potentially. And then your opponent will be able to set those off and send a ton of stuff back to you. So this is why it's not one of these games where when you get ahead, you stay ahead. It is a very interesting mechanic of perpetual comeback. Yeah. That is... I'm trying to think of other i mean scrabble is not completely dissimilar to that it definitely doesn't have like uh oh
Starting point is 00:13:33 you're about to win you could be about to lose but there it affects the strategy that you play in high level scrabble when you're down by over a 100 over like a bingo or more you start to you start to play a denial game rather than a scoring game there's defensive versus offensive and offensive you open lanes so it's you'll any high level Scrabble player is always looking at where are the bingo lanes where I can score and if there's only one and you're trying to play defensively because you're up by 150, you're just always one at a time closing that lane so that there's nowhere to score. And then the next turn, the player will try to open another lane that that person can't close. And the best kind of play is where you fork, where you open two lanes at once, which is unblockable. Because if you don't have high scoring lanes, there's no
Starting point is 00:14:25 way for you to come back. So there's kind of things like that where and even certain countries are known for the way that they train. Like I just watched a video on how Nigeria has become a Scrabble superpower because they have this one guy that won the world championship in, I think, 2016. His name was wellington and it's uh designated in nigeria uh that scrabble is a sport the same way chess is and so they have funding for training and now like it's in the top 100 there's like 40 nigerian um like globally ranked scrabble players
Starting point is 00:15:00 and there's like two in the top 10 anyways and they are all known for uh or actually i think they said it's a myth but the myth is that they play very defensively but actually the top players they're they're just as aggressive as some of the other players this is interesting you know i know that you've played scrabble somewhat competitively uh i've i've played one tournament uh you have a deeper than average understanding scrabble like i haven't played much i've played one tournament. You have a deeper than average understanding of Scrabble. Like I haven't played much. I've played Scrabble. I know how Scrabble works.
Starting point is 00:15:29 Like, but I haven't played it anything beyond, you know, with the family. And that not very much. And so, you know, I think like most people, I'm vaguely aware that in competitive Scrabble, like you need to know all the two letter words and probably all the three letter words. And four and five and six and seven whether you know the eights and nines is the question uh but then there's this whole other strategy of actually play space controlling the space of play yeah right which which is not something that is obvious. You know, most people, I think, would find it fairly obvious that knowing all the two and three letter words would be an advantage at the end of the game in particular. But the actual strategy of play of, like you say, closing lanes or opening lanes or various things and indeed the strategy over time of
Starting point is 00:16:27 managing your letter bank right to to mean that you're not looking for you're always looking for bingos i assume but you're you're not necessarily looking for them on this play you might be set trying to set up trying to you know try to go down the highest probability path to set up a bingo next turn or turn after or hopefully you know ideally every turn but um the top level play is look is thinking about things like that right yeah it's honestly even as a i would say above average like serious scrab player, there was a whole other world of strategy that I did not know existed. And still until I started watching these Will Anderson videos and, and commentators commenting on Scrabble tournaments that are now live streamed that weren't, you know,
Starting point is 00:17:16 in years past. And the things that people do are, it's incredible, like, so that one of the big things I didn't know about was endgame every every professional or uh elite scrabble player tile tracks so you know exactly at the end of the game when there's no more tiles in the bag you know exactly what you have and what they have yes and depending on the board is that something that is purely mental are there rules are they allowed to write down yeah that you can write down whatever you want so they all all players have like a little thing where they just scratch off the letters one by one. And you both keep your own scores as well as some third party. Right.
Starting point is 00:17:53 That's just kind of Scrabble rules. And so you can play out at the end of the game. You know what your opponent has. You know what they can spell. And so the obvious play for you at like a simple level is like, oh, I can score this many points. It's my best word. Could set them up to win the game in like some remarkable fashion. So you have to play out.
Starting point is 00:18:12 And depending on how many minutes you have left on your clock, because it's a timed game like chess as well, you'll see someone sit there for seven minutes finding the one path to like victory, which involves three different plays and like setting themselves up. So this is like, this is like end games in chess. Exactly. Yes. So chess, I believe, is solved for any configuration of seven or eight pieces left on the board. Computers have solved it. Something like that. Yeah.
Starting point is 00:18:41 But Scrabble is more amenable to humans finding these paths i guess because it's uh because there are a finite number of words in the dictionary in particular the two and three letter words that happen at the end so so yeah i know that um quackle is a program that can solve end games perfectly up to a certain amount as well even though there's i think 135 000 words in the scrabble dictionary depending on the dictionary you use there's a collins one and a north america one anyways right but yeah it is solvable but it is it's a lot harder to do like the best players in the world can do it but there there are some things that's incredibly hard to see and another really really cool trick like jackson smileyiley is a Canadian top world ranked player that actually was on Jimmy Kimmel years ago on that little kid contest where they bring on the two young Scrabble players.
Starting point is 00:19:34 He was, you know, when he was a kid, went on that program. I think he's roughly my age, plus or minus. And he still plays now but he is crazy for his setups that he will do where they they know oh i have the only m left and i can hook this word with an m at the end so i will put it here it'll be unblockable and then i'll wait and and so it looks like he's just kind of playing a whatever you know other elite players will recognize this and try to block but they try to set up these situations where they've they're they're putting something they're basically laying themselves up or like for an alley-oop that is unblockable because they have the only tile left in the bag
Starting point is 00:20:14 because they've been tracking and every once in a while you'll see something like i've seen before where someone played eau which is a the french for water, but it's in the Scrabble dictionary. And they put that next to a triple letter. And E-A-U-X is also a word. And they had the X on their rack. So they were setting themselves up. 30 points. No, X is eight, right?
Starting point is 00:20:37 So it's X times three. But then they played another word that ended in X. So they spelt O that ended in X plus something like tax. So you end up getting 48 points for that one letter. Wow. Because it's triple in both of the words. Yes. The X was on the triple.
Starting point is 00:20:53 Okay. And then it can look like, I mean, elite players, they automatically always recognize these things where, oh, they might be setting zed a uh dual direction triple play where you get 40 or 60 for uh six times 10 for zed or z uh for i don't actually know which one's american i know the americans yeah uh anyways zed z american say z yeah z um but like elite players will see this immediately um but if you're if i'm just playing casually, like no one's going to notice that I dropped an A next to a triple and that I might have the Z on my rack. But they'll see this immediately. And, you know, anyways, it's a very simple game in terms of like, oh, you just it's a crossword game. Speaking of which, we'll transition now an hour later.
Starting point is 00:21:40 We've got two board game episodes now. We're going to have to split this into two parts. Well, I just wanted to hook in also on the on the algorithmic side of things well we'll save the books movie but um i was gonna say um avra and i when we were dating used to play cribbage a bunch which is a great game for two players cribbage and there's another game that i get mixed up is this the one with the 29 and the pegs on the board or cribbage has yes that's right um so when yes that's right so it it there's a cribbage board has the pegs you play to 121 and 29 is the highest scoring hand okay yeah that's so and you find some cribbage boards that look like a 29 that's right
Starting point is 00:22:26 that commonly you find the 29 shape cribbage scoring is very interesting algorithmically it's it's one of those things that i periodically go back to as sort of a coding practice the coding exercise is scoring a cribbage hand because it's like i say it's algorithmically interesting to begin with um there is a there is a an order in which you count up a cribbage hand so you're looking for to begin with uh cards that sum to 15 right and your hand is four cards your hand is four cards and there's an extra starter card which you get to include in counting um there are various rules so you to start with you're looking for cards that sum to 15 ace is always one never 11 so ace is always low in cribbage so you're looking for 15s you're looking for pairs you're looking
Starting point is 00:23:20 for runs of three or more runs yeah i remember that and and what and what and then you're looking for there's a score called uh one uh it's called knobs or i say one for his knob because that's the way i was taught which is if if you're holding a jack which is the same suit as the starter card that got turned up it scores one point you can also i think score for a flush although that's rarer but what makes cribbage interesting to score is all of those things, but also the fact that it's combinatoric. So the highest scoring hand is you're holding a jack and three fives, and the turn-up card is a five of the same suit as your jack.
Starting point is 00:24:01 That hand scores 29. And the way it scores 29 is by counting 15s combinatorically. So you've got 15, 2, 15, 4, 15, 6, 15, 8. That's the jack paired with each of the fives. Right. There's eight points. Then you've got the four fives. How many ways are there to select three from four?
Starting point is 00:24:22 Because three fives are 15, right? It's like triangle building, right? 15, 2, 15, 4. Yeah, exactly. So you've got however many there are there. Then you've got all of the combinatorial pairs of fives. Again, you've got four fives. How many ways can you select a pair of fives?
Starting point is 00:24:39 You score two points for every one. Right, this is what I mean is combinatorial. And then finally, the one for knobs makes the score up to 29 that's the extra one point yeah that is yeah algorithmically interesting but also it would be very not monotonous but i'm trying to think of like the elegant way and it's like that's there's probably going to be no array single liner it's going to be a bunch of the elegant way to do it might be recursion yeah that's the way i normally do it yeah at first until it was the the example i was thinking of
Starting point is 00:25:11 like the seven eight six seven eight nine hand which usually was what i was shooting for yeah that's also a decent hand that has the a very good hand this like especially if you have say um six seven seven eight and you get a nine turned up right as soon as you get a double seven in there or a double eight then the combinatorics start to come into play because you've got 15 two with seven and eight 15 four with the other seven and eight 15 six with the six and nine then you've 4 with the other 7 and 8, 15, 6 with the 6 and 9. Then you've got the runs, and again, you're counting the runs combinatorically. So 6, 7, 8, 9 is one run, and then 6 other 7, 8, 9 is the other run, and you've got the pair of 7s as well.
Starting point is 00:25:57 So you've got a lot of different scoring in there once you start doubling up, because the 7 is doubled as part of a 15 and also doubled as part of a run it's it's multiplying up i'm actually trying to think though is that could you solve it by doing a is it permutations so no it's it's not permutations it's power set permutation so combinations is order doesn't matter permutations order matters power set permutation so combinations is order doesn't matter permutations order matters power set is all the lengths up to uh n so the question is if you took the power set i think it's and it might actually need to be the permutations of each actually no i don't think permutations matters because the the order of the cards definitely doesn't matter.
Starting point is 00:26:47 You just keep them in sorted order to check for runs. If you took the power set of the four cards you had, which for four is not going to explode that big. Right. Could you solve it? Well, it's five. The fifth card can be included if needed. That's one of the things that puts a wrinkle in it. Like, for example, you can have a flush if all the cards in your hand are the same suit,
Starting point is 00:27:11 and that scores four points. If the card that gets turned up is also that same suit, you can score five points, right? Likewise, the card that gets turned up may or may not be included in a run, depending on whether you have a run of three in your hand, that's sufficient. But if you can make a run of four you can do that too for example oh but you won't get points for a run of three if there's the run of four as well correct okay so that that breaks that breaks my power set model that i was trying to think if like if you could just create every combination of like length two three and four from your four can you map the points uniquely to each one of those and then just sum it up oh that's right yeah the run length does not apply combinatorically the contents of the run would
Starting point is 00:27:51 you swapping out cards and whatever yeah it's a it's a very interesting problem to code up um and it's interesting also just so there's now rhythmically interesting part and then there's a sort of code design part, which is how you represent the cards, how you represent the hands, how you represent the deck and dealing the hands, which applies in generally to card games, I think. Oh, so that's if you're implementing the whole game
Starting point is 00:28:16 is what you're talking about there. Yeah, yeah. Is the queen of spades a value or a reference type? Oh, yeah, yeah. Tony's famous question. Link to one of Tony's talks uh i like the way in array programming it's a pretty classic trick you just assign 1 to 52 or 0 to 51 if you wanted uh depending on your array language i think 0 to 51 works a little bit nicer though because
Starting point is 00:28:38 you can then do immediately mod uh 13 so you do mod 13 to get suits and right you because you have i'm sure you could do this in other languages but it's it's really easy to do in array languages you can do this uh index selection where you create a string of the unicode uh diamonds hearts spades and uh clubs and then you can just mod 13 you can go integer division and then index into. So like if you have 16, which will be, I don't know, like the seven of hearts or something. Or actually, no, it's going to be lower than that, the three of hearts or something. And then you integer divide that by 13, you'll get one. And then you can index into your length four string of those Unicode symbols.
Starting point is 00:29:22 And so like in a few characters by using just 0 to 51, I mean, this breaks the whole using a value versus etc. that Tony talks about. But it's a super fast way to get like a card game going and to display things in a terminal that look quite nice. Yeah, it's cool.
Starting point is 00:29:40 I mean, you also need to deal with like court cards all counting 10 as far as the 15s. That's another you know, the value of the card is not the value of the card. For the pip cards it is, but for the picture cards, they're all 10, right? Yes. So when you're counting 15s, you need to take out that kind of thing. So there are enough sort of special case rules like that to make it interesting. It's not terribly complex, but it is more complex than simply power setting the cards, right?
Starting point is 00:30:13 Yeah. Maybe we should have a whole other episode on it. Because I remember one of the very first things that I did when I fell in love with programming, because I was studying actuarial stuff in school, I had to take two programming courses. And I was actually struggling in the very first one I took was a Python course, just intro to CS. And I was never the best student, I kind of skated through high school. And so you know, if things weren't immediately obvious to me, I was just like, this isn't for me. And finally, at some point, like halfway
Starting point is 00:30:45 through the course, there was this assignment. And I was like, this can't be that hard. And so I actually sat down, tried to figure out, you know, for loops of statements and stuff. And then I was like, wait a second, like, I did the assignment. And I was like, with these like, couple tools, you could do, you could do anything. And then like, the next two to three days, like disappeared. And I wrote this like 3000 line poker simulation. Cause at the time I was a big fan of, uh, poker, not gambling. Cause I couldn't gamble yet. I was too young.
Starting point is 00:31:14 That's a whole different story. I don't gamble anymore. Probability. Yeah. Yeah. And, uh, hence you went into actuarial sense. Yeah. Statistics money.
Starting point is 00:31:23 I mean, there's, there's a whole books written about, you know, the overlap between Wall Street and poker and whatnot. Anyways, and that program that I wrote, though, was identifying the different hands. And all of it was nested for loops. I wish I could go find the code. It's on some hard drive somewhere. But it was horrific. But it worked for the most part and now i have like in small talk and bq in a couple languages these one-liners using like specific frequency uh methods or
Starting point is 00:31:53 collections that make it so much faster so much more beautiful it's it would be interesting to go back and refactor in the sense i think a lot of students too i remember helping uh someone that was doing a kind of poker assignment once and they were blown away when i was they were doing an elixir and i was like oh yeah elixir has all this stuff you know chunk by etc and they were like what the heck i was just gonna loop through this stuff and i was like yeah that's exactly how i would have thought when i was first learning it yeah i have a similar story one of the earliest things i wrote when i was a teenager in QBasic, QuickBasic, actually.
Starting point is 00:32:28 Jason would say there's a difference between those. Was Yahtzee. I wrote a Yahtzee program that I spent a whole summer playing with my brother and sister. We would play together and, you know, it was the whole game. So it rolled the dice and then you could choose where to put the score and hold and all that, the play of Yahtzee. I see you have Yahtzee behind you there.
Starting point is 00:32:50 I love Yahtzee. Yahtzee is my favorite party game. It's another game where there is a hidden strategy, right, I think, that's beyond the surface meaning of the game, if you like. Because as a kid learning Yahtzee, I didn't fully understand that one of the strategies is like, you know, you roll the dice and you get a certain score, right? You get a certain outcome.
Starting point is 00:33:21 And then you can choose where to score those dice right and you don't have to score them in places where they obviously score or places that you were going for right if they come out bad you could choose to take a zero in the ones exactly for example right because the most you can ever get in the ones is is five or five yeah uh with the bonus yahtzee admittedly but four let's say the most you're likely to get in the ones is four um so i had not appreciated that whole level of strategy when i first started playing yahtzee at the age of eight or whatever yeah yahtzee is a a game that is mostly luck i don't know if it's 90 10 luck and skill but i love i love yahtzee not typically it's like a new year's eve a party game where there's lots of people and uh i also
Starting point is 00:34:13 too like i my strategy is like i throw full houses i don't care if it's my second i'm always going for yahtzee it's like i want the 500 game i think i scored 450 one time but that admittedly is like every opportunity i have to get a yahtzee i'm i'm gonna take it because even if there's a one in 216 whatever six of the power three is like i still have a shot and it's worth the 100 points bonus to me to like end up with 170 which is not a great score to like you know end up with a game once every 20 games that's like you know 400 plus stella which is like three or four yahtze once every 20 games that's like you know 400 plus stellar which is like three or four yahtzees uh because like that's it's it's worth it to suffer through 19 games to have this one glorious moment which is also the same way that i i race races is
Starting point is 00:34:55 i always go out too hard and it usually doesn't go well but then one day it's a great day um yeah one day when everything lines up you go out hard and you find you're able to continue and you run a negative split. See, I know some running terminology. Be sure to check these show notes either in your podcast app or at ADSPthePodcast.com for links to anything we mentioned in today's episode as well as a link to a GitHub discussion where
Starting point is 00:35:17 you can leave thoughts, comments, and questions. Thanks for listening. We hope you enjoyed and have a great day. I am the anti-brace. Um...

There aren't comments yet for this episode. Click on any sentence in the transcript to leave a comment.