question: private void printProgress ( long row , long rowFrom , long rowTill ) { long rowsProcessed = row + chunkSize - rowFrom ; if ( rowsProcessed > ( rowTill - rowFrom ) ) rowsProcessed = ( rowTill - rowFrom ) ; print ( String . format ( "%d%%" , ( int ) ( ( ( double ) ( rowsProcessed ) / ( double ) ( rowTill - rowFrom ) ) * 100.0f ) ) ) ; }
target:  Render (print) progress bar.