Rising stars or shooting stars

I have lamented in the past about organization structures in India that promote people to dizzying heights in a short span of time. These people are the ‘rising stars’ and they never gain expertise in any field. They pick a plum technical project to work on so that the next appraisal process favors them not because they are experts but because they are part of a highly visible team that boosted the financial success of the firm.

This is from ‘The Five stages of Capacity Planning’ by H Pat Artis

“Because capacity planning in this stage is a high visibility special project, it is often assigned to rising stars who will have long since been promoted by the time of the next planning cycle occurs.”

These rising stars are shooting stars who do not continue as technical leads and a newer crop of junior people take their place leading to standards that fall precipitously.

Rounding decimal digits

Price in Decimal digits is difficult to pay if your currency does not have low-value coins in circulation. So decimal digits might have to be rounded to the nearest value so that a figure like 0.56 can be paid. java.Math has MathContext and RoundingMode to round decimal digits.

So there is a precision that we specify. In the following code the precision is ’1′ which means that .5625 is rounded to .6. We have rounded to 1 digit and the precision is lost but we ensure that the digits are either 0.5 or 0.6 depending on which is the nearest.

BigDecimal tax = new BigDecimal( 0.5625,
			new MathContext( 1,
 				RoundingMode.HALF_UP));

Output : 0.6

BigDecimal tax2 = new BigDecimal( 0.5325,
			new MathContext( 1,
				RoundingMode.HALF_UP));

Output : 0.5

BigDecimal tax2 = new BigDecimal( 0.5525,
			new MathContext( 1,
				RoundingMode.HALF_UP));

Output : 0.6 ( 0.55 is equidistant from 0.5 and 0.6. So it is rounded up to 0.6 )

Follow

Get every new post delivered to your Inbox.