Which is a better option?
It's not always that when you have something creative your code is going to look ugly.
But at times it does go a bit ugly.
e.g.
if ( (object1(0)==object2(0) &&
(object1(1)==object2(1) &&
(object1(2)==object2(2) &&
(object1(3)==object2(3) )
retval = true;
else
retval = false;
is simple and readable
bool retValue = (object1(0)==object2(0)) &&
(object1(1)==object2(1)) &&
(object1(2)==object2(2)) &&
(object1(3)==object2(3));
but having something like this will make some newbies scratch their heads.
So what do I go for? including simple code everywhere might sometime hamper my performance.
What I could think of was commenting wherever necessary but at times you get too curious to know what is actually happening.
