Thursday, September 24, 2015

Another way to talk about CQRS/Event Sourcing

"A more promising model, used in some systems, is to think of a database as an always-growing collection of immutable facts. You can query it at some point in time — but that’s still old, imperative style thinking. A more fruitful approach is to take the streams of facts as they come in, and functionally process them in real-time."

Turning the database inside-out with Apache Samz

Monday, September 14, 2015

How to swap two numbers without third variable?

int first,second ;
first = 1;
second = 2;
first = first + second;
second = first - second;
first = first - second;