#!/usr/bin/perl -w

# ------------------------------------- 

# In a group of N people, what is the likelihood that the last 4
# digits of their Social Security Numbers are different?

$N=100; #number of people
$B=1;
print "\n\n";

for ($K=0; $K <=N; $K++) {
	$B =$B*(1 - $K/10000);
	$k = $K+1;
#print "$k   $B\n";
	if (($k % 5) == 0) {print "  $k   $B\n";}
}
