traverses the configuration and processes each entry
perfectshuffle(configuration,n)