/* Create a left rotation and a right rotation function * that returns all the left rotations and right rotations of a string. * leftRotations("abc") ➞ ["abc", "bca", "cab"] * rightRotations("abc") ➞ ["abc", "cab", "bca"] */ // left rotation takes the front character and adds it to the back std::vector leftRotations(std::string str) { std::vector result = {str}; // function will run for the length of a string for(int i = 0;i rightRotations(std::string str) { std::vector result = {str}; int end = str.size()-1; // function will run for the length of a string for(int i = 0;i