changed a simple typo

the previous code worked only for 4 nodes