printf("number of tags..................... %5lu\n", num_tags);
printf("number of unique tags.............. %5u\n", num_unique_tags);
printf("average number of epigrams per file %8.02f\n",
- (float)num_epis / num_epi_files);
- printf("average number of tags per epigram. %8.02f\n",
- (float)num_tags / num_epis);
- printf("average number of tag recurrence... %8.02f\n",
- (float)num_tags / num_unique_tags);
+ num_epi_files > 0? (float)num_epis / num_epi_files : 0);
+ printf("average number of tags per epigram. %8.02f\n", num_epis > 0?
+ (float)num_tags / num_epis : 0);
+ printf("average number of tag recurrence... %8.02f\n", num_unique_tags > 0?
+ (float)num_tags / num_unique_tags : 0);
if (verbose) {
printf("\nlinear hashing statistics:\n%s\n", lh_stats);
free(lh_stats);