Archives
-
[Articles] Brad Abrams: The Bum Rap of foreach
Recursively follow all of the links in Brad Abrams article The Bum Rap of foreach and you will get a great education in both iteration and the evils and joys of micro-optimization. Regarding optimization, see "Rule #1" in The Rules of Optimization.
-
[.NET - CSharp] Nice Little String Rotator
These string rotator methods appeared in a chain of recent posts on the DOTNET-CLR list. I recorded them here because they may prove useful.
-
[SoftDev] Bit Rotation
This article on Bit Rotation for Byte, Short and Int Variables in Java could easily be adapted to C#.
-
[Tools] Free Metrics Tools
I just tried out two new free tools that provide metrics for .NET projects and recommend both of them to anyone who wants a better picture of their .NET code. The tools are:
-
[Languages] New home for Lambda the Ultimate
Lambda the Ultimate has a new home.
-
[.NET - CSharp] DCOM server in C#
Worthy of note is this post on How to write a DCOM server in C#.
-
[SoftDev] Internationalization Karma
Now I have a karmic obligation to link to Iñtërnâtiônàlizætiøn, Scott Hanselman's recent weblog post containing some good links to internationalization resources. There! My karma feels at least a little bit better!
-
[.NET - CSharp] C# Bit Reversal
I just posted a new short article on how to Use C# to Reverse the Bits in a System.Byte There are many ways to accomplish bit reversal, and this one is not the most efficient, but my NUnit tests tell me that it works. If you have a better way, please feel free to comment!
-
Use C# to Reverse the Bits in a System.Byte
During an employment search, some time back, I applied for a senior C++ opportunity at Kyocera Wireless, in San Diego. I was invited to the company's office to take a test. As a senior .NET architect and engineer, pretty much all of the tests with which I deal are performed by NUnit, not people. Nevertheless, the economy was in such a condition at that point that I went anyway. When I arrived, I soon observed that the foyer was quickly filling up with people - most of whom had obviously been in school quite recently. This collection of nameless potential "human resources" was efficiently [the best word I can find is] herded into a number of small offices to be given a timed test. Although I was supposedly under consideration for a senior object-oriented C++ position, the test was specifically targeted toward straight "C" hacks. I will not bore my valued readers with either the details or the results, other than to proclaim that I do not currently work at Kyocera. Neither would I ever be likely to work for a company that chooses to humiliate candidates in this manner.
-
[.NET - CSharp] Speaking of Singleton
Speaking of using the Singleton pattern in C#, have a look at Design Patterns potential hazards on Fabrice's weblog and follow the links to the articles he recommends. Also, have a gander at .Net singleton pattern multi-threading issue... by Chris Johnson. An old friend (and ex co-worker) just sent me another great link to an IBM Developer Works article with advice on how to Use your singletons wisely. MSDN has Implementing Singleton in C#, as pointed out by Luciano Evaristo Guerche who was recently cited by Scott Watermasysk. A comment in Luciano's post also points to Implementing the Singleton Pattern in C#.
-
[Languages] Twist of Fate: a C-Compiler in Python
Now this is an interesting twist: Atul's Mini-C Compiler is a C-compiler written in Python. I would make the appropriate allusions to Ouroboros, the snake that eats its own tail, but, as every software professional should know, those allusions would be quite inappropriate because Python was named after "Monty Python," not any variety of snake (see "1.16 Why is it called Python?" from the General Python FAQ).
-
[.NET - CSharp] Software Design Patterns in C#
The Data and Object Factory has a nice presentation of software design patterns including downloadable source code in C#. You will probably find a visit there worthwhile. For each pattern, the authors provide a structural example and a "real world" example. The code is generally clear, concise, and instructive. For example, take a look at the very simple but cool "real world" example where the authors show how to use Singleton to implement a rudimentary LoadBalancer object. Nice!
-
[.NET - General] Comment-Driven Development (CDD) (TM)
A recent secretGeek post on TODO-Driven Development may have started out as a somewhat tongue-in-cheek parody, but I am among the first to admit that I have used this "new" methodology successfully many times! While I now believe that Test-Driven Development (TDD) is a better way to go (when you can), I still use the TODO-Driven approach sometimes.