 | Displaying Relative Time When developing software that works with time stamped information, it is common to show the date and time at which an item was created or last updated. A user-friendly alternative is to display a relative time, such as "Two Hours Ago". |
 | The Soundex Algorithm Cultural differences and input errors can lead to words being spelled differently to a user's expectations. This makes it difficult to locate information quickly. The Soundex algorithm can alleviate this by assigning codes based upon the sound of words. |
 | Calculate the Number of Business Days in a Range A common task is to calculate the number of business days that exist within a date range. In most western cultures, these are the days from Monday to Friday and excluding Saturdays and Sundays. The resultant number should also exclude national holidays. |
 | The Chaos Game and the Sierpinski Triangle The chaos game is a method for generating fractal images by plotting randomised points inside a polygon according to a simple set of rules. In this article we will use the chaos game to generate the Sierpinski triangle using C# and Windows Forms. |
 | Calculating a Person's Age in Years Sometimes you will want to calculate the age of a person or of an object and return a result specifying the age in years. This calculation is simple to perform using the properties of the .NET framework's DateTime structure and basic arithmetic operators. |
 | Convert a Number to an Ordinal Number Ordinal numbers represent the rank of a cardinal number, such as 1st, 2nd and 3rd. These numbers define the position or rank of a value, rather than just the size or quantity. In this article we will convert integers into English ordinal numbers. |
 | A Generic Read-Only Dictionary The .NET framework includes several types of collection that are designed for use in object models. Amongst these is the ReadOnlyCollection that allows the creation of collections that may not be modified. However, there is no read-only Dictionary type. |
 | Calculating Prime Factors in C# The prime factors of a number are all of the prime numbers that can be divided into the number without a remainder. In this article, we will create a method that uses direct search factorisation to generate the list of prime factors for a given value. |
 | Palindrome Tester A palindrome is a word or phrase that reads the same backwards as it does forwards, for example "Madam, I'm Adam". This article describes a simple method for testing the validity of palindrome using basic string manipulation functionality. |
 | Vista-Style File Size Formatter When copying files, Microsoft Windows Vista shows a dialog box that indicates the size of the remaining items to be processed and the copying speed. The values are formatted with three significant figures. This article explains how to recreate this style. |
|
|