Welcome to MSDN Blogs Sign in | Join | Help

January 2008 - Posts

Why threading is hard

Anybody who says "I can write correct multi threaded code" probably should be saying "I don't test my multi-threaded code". It is very difficult to write correct multi-threaded code. One way to appreciate this is various "find-the-bug" pop quizzes that
Posted by jmstall | 8 Comments
Filed under:

Quiz: can you count how many combinations ...

Here's a combinatorics quiz: If you have 2 ordered lists (lengths N, M), how many ways can they be interleaved into a single list while still preserving the partial ordering from the original lists? So if the lists were: List 1: A,B List 2: X,Y The following
Posted by jmstall | 10 Comments
Filed under: , ,

Lang.Net 2008 is coming

Lang.Net 2008 is coming up this Monday through wed (Jan 28th -Jan 30th). This is targeted at compiler and language implementers. The agenda is here and includes a lot of great Microsoft and non-Microsoft folks. In my former debugging life , my angle for
Posted by jmstall | 0 Comments

Battle Simulation: size vs. smarts (part 3)

How much stupidity does it take to prevail over intelligence? I previously explored simulating Real-time-strategy battles with IronPython . ( Part 1 , Part 2 ). We saw that even with very simple rules, different strategies are better than others. If two
Posted by jmstall | 3 Comments
Filed under:

Battle Simulations with Iron Python (part 2)

I previously wrote about modeling RTS battles with IronPython . In this entry I'll explore a new policy for attacking that was suggested on the last thread. Previously, I compared 2 policies for picking which opponent to attack: 1. Attack the weakest
Posted by jmstall | 2 Comments
Filed under:

Partial Classes and future-proof vindication

A common question is "How can my tool crack the PDB to automatically determine what source file / line number a .NET class is defined in?" It's a trick question. There's a problem with the question. A .NET class may not be defined at a single source file
Posted by jmstall | 0 Comments

An extra 1 gig of memory works wonders...

I had previously installed Vista on my home machine , which had 1 GB. Vista was neat, and Civ 4 continued to work, so all was well. However, some operations, such as switching users, launching applications cold, and alt+tabbing out of a full screen game,
Posted by jmstall | 2 Comments

Zune's killer feature

Zune' s killer feature (according to my 2 year old daughter) is the box. For the 4gb/8gb, the box is sturdily built and has 2 parts that slide together. Truly a product for the whole family.
Posted by jmstall | 3 Comments
Filed under: ,

"Managed Humans" by Michael Lopp

I just finished reading " Managing Humans " by Michael Lopp, who writes at http://www.randsinrepose.com/ . My summary of it is "I've been around the block, I've got a lot experience, here's what I've observed". It's broken into concise chapters conveying
Posted by jmstall | 0 Comments
Filed under:

RTS Battle simulation with IronPython

I used Python to simulate Age of Empires archer battles. I wanted to be able to answer questions like: If 12 archers attack 10 archers, what will the margin of victory be? If two armies of the same size attack each other, how do different strategies affect
Posted by jmstall | 7 Comments
Filed under: , ,

Attachment(s): sim3.py
 
Page view tracker