Blog Archives

A Calculation of Odds in the Dice Game Langur Burja

A Calculation of Odds in the Dice Game Langur Burja

Gale Richard Walker
September 2017

Kids playing langur-burja

Kids playing langur-burja at Malekhu in Dhading district. (Bijay Gajmer/Republica)

Langur Burja, a dice game popular in Nepal and in the British navy (where it is known as Crown and Anchor), uses six identical dice, each with six different symbols on it. After bets are placed, the banker tosses all six dice at once. The betting rules and payouts to the players may be found on the Internet. Variations of the game are played in France, Vietnam, China, Belgium, and Bermuda. They are not described here.

Overall, the Langur Burja banker (commonly know as “The House”) who tosses the dice has a big edge — eight percent — over the players, but that is not the focus here. The purpose here is to show how to calculate the probability of each possible outcome of one toss of six dice. Any six symbols, pictures, colors, or numbers will do. In England, for example, the six symbols are a heart, a spade, a diamond, a club, a crown, and an anchor. Herein they are simply called colors, as any six colors on each die will do.

Continue reading “A Calculation of Odds in the Dice Game Langur Burja” »

Posted in unsorted

enabling CORS on Apache

Many people struggle to get CORS (Cross-Origin Resource Sharing) enabled on their site to allow transmission of JSON, XML, or some other sort of data from one script to another, running on different domains. Simply adding Header always set Access-Control-Allow-Origin “*”  to .htaccess doesn’t do the trick for me.

Here’s what worked for me on Apache version 2.4.33… Continue reading “enabling CORS on Apache” »

Tagged with: , , , ,
Posted in how-to, resources, unsorted

for the people copy + spread!

You must unlearn all you know!

Posted in unsorted

accelerating WordPress

Once a WordPress site is built out with themes, plug-ins, and what-not, the overall number of files necessary to transfer to the client increases. Each requests takes some time. Compiling code into fewer, smaller files can help speed the loading time for your visitors. One WordPress plug-in that enables this is Autoptimize.

Before using this plugin, this page requires 41 separate downloads:

After enabling Autoptimize, there are only 27 requests:

Posted in unsorted

presidential trivia motivation

Here are some inspirational facts about US Presidents!

Draw your workout inspiration from sixth President John Quincy Adams, who was known for taking nude early morning swims in the Potomac River. #presidentialtriviamotivation

Don’t be President Taft, the fattest president who topped out over 300 pounds. He had the White House bath tub replaced after he got stuck in it. However, he is also the only president who also served as Chief Justice of the Supreme Court, so it never seemed to hold him back! #presidentialtriviamotivation

Be more committed than James K Polk (#11). He ran for president on a promise not to run for a second term, a pledge he kept.

You know who else was bad ass? Millard Fillmore (#13). He was once captured by pirates, lived among them for months, and then over threw the ship and commandeered that shit back to Boston harbor. The pirates were hanged. And Millard became president.

Get sexy to snag a hunky bachelor, like fifteenth president James Buchanan, the only president to remain single his entire life. Oh, yeah…(Grover Cleveland was initially single but got married in June after taking office.) Of course there are rumors Buchanan was gay. There is actually a case to be made that he had a love affair with William Rufus King, the only unmarried Vice President. #presidentialtriviamotivation

The harder you work out, the harder you can live it up. Like 17th president Andrew Jackson. He was noticeably drunk during his inauguration speech. No wonder he is only one of two presidents to be successfully impeached. He is also arguably the worst president in history and a racist douchbag. Pretty much.

If you, on the other hand, are more like Rutherford B. Hayes, however, you may need to loosen up. He banned alcohol from the White House to get support of the Prohibitionists (though history of course blames the woman. his wife is known as Lemonade Lucy and though she did frown upon alcohol, but it was really the dude making political moves that made the decision. or so i hear). So, that’s not the weirdest thing about Rutherford B. Hayes, though. He is a hero is Paraguay. A real hero. He signed some treaty that granted them most of their land, and they celebrate him like he is Abraham Lincoln. The have towns named for him, a museum, a freaking holiday. Asuncion, the capital city, named its soccer team “Presidente Hayes Soccer Club.” Crazy, right?

Working it too hard? Slow down, fella, or you’ll end up like US Grant (#18) who once got a speeding ticket. On his horse.

Tagged with: , ,
Posted in unsorted

results of a recent wardrive

During a recent Sunday afternoon cruise, I collected the names and locations of all the WiFi routers in range of my car. Some of the access point names are creative, listed here. (I omitted the many openly vulgar ones one would expect to find in a college town.)

Plays on “WiFi”1000px-Osa_device-wireless-router.svg

Pretty Fly For a WiFi
So fly for wifi
WiFi Art Though Romeo?
WiFi? Why not Zoidberg?
WiSoSerious
4OH!4–Dont Trust Our Wifi
4Fer my wife-i
99 Problems, but WIFi ain’t one
A Lannister always pays his wifi
AINT NO WI-FEY
Bill Wi the Science Fi
wedonthavewifi
The Creepy Wifi from Doctor Who

Continue reading “results of a recent wardrive” »

Tagged with: , , , , ,
Posted in unsorted

FAQ QA

Here’s a snippet from an Adobe FAQ regarding the CS6 package. The web design lesson here is to make sure that the answers to questions answer the questions.

Here’s what Adobe is telling me:

The question: What is the installation and activation process?

The answer: New.

That’s a completely useless answer and does not describe the process at all. If you’re involved in drafting something like this, ask yourself: does this really answer the question?

Tagged with: , , , , , , ,
Posted in unsorted

hero proposition

An hero

I propose a redefinition of

hero (masculine) or heroine (feminine) refers to characters who, in the face of danger and adversity or from a position of weakness, display courage and the will for self sacrifice—that is, heroism—for some greater good of all humanity.

hero (masculine) or heroine (feminine) refers to people who, in the face of racism, classism, occupational hazard or from a position of poverty, display courage and the will for self sacrifice—that is, heroism—for the greater good of their community.

Tagged with:
Posted in unsorted
filter