![]() Problems of this form are quite common in practice for instance, it may be desirable to find orderings of boys and girls, students of different grades, or. When some of those objects are identical, the situation is transformed into a problem about permutations with repetition. In other words, the number of ways to “permute” or move around 1 person is just 1. A permutation of a set of objects is an ordering of those objects. But, we are told that the teacher must sit on the left end. this element is added to all the permutations of the remaining elements (If you use a pen and paper and walk through the procedure of the function step by step it will be much easier to understand). ![]() In this case, we have 15 people (14 students and a teacher). Using this logic, the permutations function takes each element from the array and sets it as the first element of the resulting permutation (this is the outer loop). In how many ways can this be done if the teacher must be seated at the left end only?
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |