removed unsigned from top to bottom loop