Saturday, March 31, 2007

Domain-based email: http://www.stubmail.com

Amdahl's law: http://en.wikipedia.org/wiki/Amdahl's_law
Good site for web-based messenger site: http://www.meebo.com

Good site for listening to music: http://www.pandora.com
When you include a header file, you introduce a dependency that will
cause your code to be recompiled whenever the header file changes.
If your header file includes other header files, any changes
to those files will cause any code that includes your header to
be recompiled.
class Foo {
public:
Foo() : bar_("foo_bar") {}

private:
const string bar_;
};


In this C++ code, you should not declare bar_ as
const string& because the initializer creates an instance
of string with "foo_bar" char* and it will be destroyed
immediately after it is out of scope if it is referenced.

Monday, March 26, 2007

Ruby tutorial: http://www.ruby-lang.org/en/

Program to convert epoch integer following "epoch_time" to human-readable string.

if __FILE__ == $0
IO.foreach("querylog.txt") {
|x|
print "" + (x[0,10] == "epoch_time" ?
x[0,10] + ": " + (Time.at(x[11..x.size].to_i)).to_s + "\n" :
x)
}
end

Wednesday, March 21, 2007

Law of Demeter

When I refactor a class and feel that this class is doing too much,

then I have to say that there might be a better way of dealing with this.



http://en.wikipedia.org/wiki/Law_of_Demeter





powered by performancing firefox