0

n person will go to a meeting. The meeting will be happen once a day and everybody will sit around a round table. The question is how many days have to arrange each day and how to arrange so that each person will have two people next to them who are new friends. Note that all people want to get to know each others.

n must be an odd number

For example, when n = 11 The number of days has to be (n-1)/2 The programme must print:

1 2 3 4 5 6 7 8 9 10 11 1

1 3 5 2 7 4 9 6 11 8 10 1

1 5 7 3 9 2 11 4 10 6 8 1

1 7 9 5 11 3 10 2 8 4 6 1

1 9 11 7 10 5 8 3 6 2 4 1

How can solve this problem with python ?

0 Answers0