How to print number of blocks in a region in Drupal 6
The following query returns the number of blocks in the left region of the current theme.
Replace left with your region name.

$current_theme = variable_get('theme_default', '');
$number_of_blocks = db_result(db_query("SELECT COUNT(*) FROM {blocks} WHERE theme='%s' AND region='%s'", $current_theme, 'left'));