converting bottom->top n dec value