public class DougMcIlroyAlgorithm<T extends java.lang.Comparable> extends java.lang.Object implements RotationEngine<T>
ARRAY_IS_EMPTY, DATA_TYPE_NOT_SUPPORTED_YET, DECIMAL_RADIX, DELIMITER_COMMA, ELEMENT_NOT_FOUND, LIST_IS_EMPTY, OPERATION_NOT_SUPPORTED_YET
Constructor and Description |
---|
DougMcIlroyAlgorithm() |
Modifier and Type | Method and Description |
---|---|
ListNode<T> |
rotate(ListNode<T> listNode,
int k,
boolean clockwise) |
T[] |
rotate(T[] objects,
int k,
boolean clockwise) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isRotation, isRotation
checkArray, checkIntArray, checkList
public T[] rotate(T[] objects, int k, boolean clockwise)
rotate
in interface RotationEngine<T extends java.lang.Comparable>