compute bogosort