background preloader

Computing Science

Facebook Twitter

Math

Big-O Algorithm Complexity Cheat Sheet (Know Thy Complexities!) @ericdrowell. Storing UTC is not a silver bullet. Note: this is a pretty long post.

Storing UTC is not a silver bullet

If you’re not interested in the details, the conclusion at the bottom is intended to be read in a standalone fashion. There’s also a related blog post by Lau Taarnskov – if you find this one difficult to read for whatever reason, maybe give that a try. When I read Stack Overflow questions involving time zones, there’s almost always someone giving the advice to only ever store UTC. Convert to UTC as soon as you can, and convert back to a target time zone as late as you can, for display purposes, and you’ll never have a time zone issue again, they say. This blog post is intended to provide a counterpoint to that advice. Note on simplifications: this blog post does not go into supporting non-Gregorian calendar systems, or leap seconds.

The timing of this blog post is due to recent European Parliament proceedings that look like they will probably end the clocks changing twice a year into “summer time” or “winter time” within EU member states. Result Result. Peter Norvig. A billion monkeys can't be wrong. In his now infamous blog post “The Duct Tape Programmer”, Joel Spolsky quoted Jamie Zawinski from my interview with him in Coders at Work talking about how they didn’t use many unit tests when developing Netscape.

A billion monkeys can't be wrong

“Uncle Bob” Martin, chiming in to say that Spolsky posting was right in general but wrong in almost all his specific claims and criticisms, was particularly riled by Spolsky’s implication that maybe unit tests aren’t 100% necessary at all times: As for Joel’s consistent dismissal of unit testing, he’s just wrong about that. Unit testing (done TDD style) does not slow you down, it speeds you up. One day I hope Joel eventually realizes this. Programmers who say they don’t have time to write tests are living in the stone age. Tim Bray also jumped in to strongly agree with Uncle Bob on the importance of unit tests, though he couldn’t bring himself to actually agree with much else Uncle Bob said.

The builder pattern in practice – Development the way it should be. So, this is my first post (and my first blog for that matter).

The builder pattern in practice – Development the way it should be

I can’t remember exactly where I read this (although I’m almost sure it was on Practices of an Agile Developer), but writing in a blog is supposed to help you get your thoughts together. Concretely, by taking the time to explain what you know, you get a better understanding of it yourself. And that’s exactly what I’m going to try to do here, explain things to get a better understanding of them. And, as a bonus, it will also serve me as centralized place to go to when I want to revisit something I’ve done in the past. Hopefully, this will help some of you in the process. With the introduction out of the way, lets jump straight into this first post which, as the title so eloquently says :), is about the builder pattern.

Imagine you have a class with a substantial amount of attributes like the User class below. Now, imagine that some of the attributes in your class are required while others are optional. Builder .NET Design Pattern in C# and VB - dofactory.com. Definition Separate the construction of a complex object from its representation so that the same construction process can create different representations.

Builder .NET Design Pattern in C# and VB - dofactory.com

Frequency of use: Medium low The classes and objects participating in this pattern are: Builder (VehicleBuilder) specifies an abstract interface for creating parts of a Product object ConcreteBuilder (MotorCycleBuilder, CarBuilder, ScooterBuilder) constructs and assembles parts of the product by implementing the Builder interface defines and keeps track of the representation it creates provides an interface for retrieving the product Director (Shop) constructs an object using the Builder interface Product (Vehicle) represents the complex object under construction. Structural code in C# This structural code demonstrates the Builder pattern in which complex objects are created in a step-by-step fashion.

Output Product Parts ------- PartA PartB Product Parts ------- PartX PartY. Wexflow: Open source workflow engine in C# - CodeProject. This open source project is sponsored by JetBrains.

Wexflow: Open source workflow engine in C# - CodeProject

Table of contents Workflows Made Easy Introduction Wexflow is an open source extensible and multithreaded workflow engine written in C# with a cross platform manager app that works on Windows, macOS, Linux and Android. Wexflow aims to make automations, workflow processes, long-running processes and interactions between systems, applications and folks easy, straitforward and clean. A workflow is a series of distinct steps or phases. Wexflow provides the following features:

Distributed Computing

Algorithms. Algorithms. Abstraction and Detail. Abstraction and DetailA Conversation with Andy Hunt and Dave Thomas, Part IVby Bill VennersMarch 24, 2003 Page 1 of 3 >> Summary Pragmatic Programmers Andy Hunt and Dave Thomas talk with Bill Venners about an approach to design in which details are pulled out of the code and stored as metadata.

Abstraction and Detail

Andy Hunt and Dave Thomas are the Pragmatic Programmers, recognized internationally as experts in the development of high-quality software. Their best-selling book of software best practices, The Pragmatic Programmer: From Journeyman to Master (Addison-Wesley, 1999), is filled with practical advice on a wide range of software development issues.

They also authored Programming Ruby: A Pragmatic Programmer's Guide (Addison-Wesley, 2000), and helped to write the now famous Agile Manifesto. Orthogonality and the DRY Principle. Orthogonality and the DRY PrincipleA Conversation with Andy Hunt and Dave Thomas, Part IIby Bill VennersMarch 10, 2003 << Page 3 of 3 Bill Venners: What does orthogonality mean and why is it good?

Orthogonality and the DRY Principle

Andy Hunt: The basic idea of orthogonality is that things that are not related conceptually should not be related in the system. Parts of the architecture that really have nothing to do with the other, such as the database and the UI, should not need to be changed together.

Methadology