Check If Strings Are Rotations Of Each Other | Python Example

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

Nice technique. I was thinking that we first find a match of the first char( so find p in thonpy). Then calculate the index difference. Using that difference we create a rotated string from string one and compare that with string 2.

But that would be really tiresome. Your solution is easy to understand. Thank you

RustysAdventures