On a procedure to test whether the random variables of a sequence are independent and identically distributed, with applications to telephone and packet-switched networks