MCPcopy Create free account
hub / github.com/TheAlgorithms/C-Plus-Plus / TryLeftRotate

Method TryLeftRotate

data_structures/tree_234.cpp:778–796  ·  view source on GitHub ↗

* @brief A handy function to try if we can do a left rotate to the target * node * * Given two node, the parent and the target child, the left rotate * operation is uniquely identified. The source node must be the right * sibling of the target child. The operation can be successfully done if * the to_child has a right sibling and its right sibling is not 2-node. * * @param parent the paren

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Calls 4

GetChildIndexMethod · 0.80
GetCountMethod · 0.80
GetChildMethod · 0.80
Is2NodeMethod · 0.80

Tested by

no test coverage detected