Wednesday, July 19, 2023

OR & NOR in Chess

Chess game has fascinated me since my childhood, there are lots of interesting facts about it. My favorite piece on the board is Knight. It can hop and do deceiving attacks with its mysterious capabilities. Basically, the square it can land on is not obvious and makes the opponent overlook or miss the attack. I have been taught that Knight moves in L or 7- shape. The steps were not intuitive to me and I was not able to get a convincing explanation for the same until recently. When I found the reason, it only increased my admiration for the inventor of the game.

Before going to Knight, let's look at other pieces on the board.

The Rook: Rooks move in straight lines along ranks (horizontally) and files (vertically). They can move an unlimited number of squares in any of these directions, making them powerful long-range pieces.

The Bishop: Bishops, on the other hand, move diagonally across the chessboard. Like rooks, they can also move an unlimited number of squares along their respective diagonals, granting them extensive influence over the board.

The Queen: - The queen can move to all squares which a rook can move or a bishop can move. Most powerful in the chess world! 

Now, the Knight: The knight can move to a square which neither Bishop NOR Rook can go, or simply a queen cannot go. This makes the player to hard to foresee any fork attacks, which knights are good at. 

Knight is a real-world use case of NOR operation, that's common in the Computer Science field.

Monday, July 17, 2023

Hungry Vacuum cleaner

Yesterday, my niece visited our house. I get excited playing with kids, especially toddlers. I was running the Vacuum cleaner and she was curious looking at it. I let her push the button that triggers the suction. She started collecting objects from the floor and kept them near the head of the vacuum. The cleaner sucked them and they started appearing in the transparent bin, and she was excited to see them piling up there. I said it's a hungry vacuum cleaner and it eats them and puts them in its tummy! She cheered this idea of a hungry vacuum cleaner!

Usually, I don't extend such ideas to stories since I am not good at it! But not so now. I took the help of ChatGPT to translate this into a good story.

I asked ChatGPT to write a story of a hungry vacuum cleaner catered to toddlers. It gave a big one, which only a middle schooler can read. Then I said, it's too verbose, then it refined the same to an elementary schooler :-). I gave the feedback again, but this time I asked more precisely to have the story format similar to the famous Hungry Caterpillar. It gave a good format now but was still using complex words for toddlers. I took it and modified it. Here it is, for your eyes!

Once upon a time, there was a hungry vacuum cleaner, Dustie.

On Monday, Dustie ate a pile of crumbs like rolling drums!

On Tuesday, Dustie gobbled up spilled juice! Papa and Mommy for a truce!

On Wednesday, Dustie sucked up brother's toy with joy!

On Thursday, Dustie zoomed around the room, and finds no doom!

On Friday, Dustie munched a bowl of popcorn with its long horn!

On Saturday, Dustie speeded like a tornado and wipes out all the play dough!

On Sunday, Dustie needs a recharge to meet you next week!