master > master: code - minor
This commit is contained in:
@@ -21,7 +21,7 @@ import (
|
||||
* ---------------------------------------------------------------- */
|
||||
|
||||
/*
|
||||
Inputs: L = Liste von Zahlen, x = Zahl.
|
||||
Inputs: L = Liste von Zahlen.
|
||||
|
||||
Outputs: Liste von Paaren von Elementen und ihrem nächsten größeren Element
|
||||
*/
|
||||
@@ -42,7 +42,7 @@ func NextGreaterElement(L []int) [][2]int {
|
||||
element := S.TOP()
|
||||
if element < nextElement {
|
||||
// falls top Element < next Element, zum Output hinzufügen und vom Stack entfernen
|
||||
logging.Debug("Stack S | %v; top Element > nextElement; ==> pop und Paar zum Output hinzufügen", S)
|
||||
logging.Debug("Stack S | %v; top Element < nextElement; ==> pop und Paar zum Output hinzufügen", S)
|
||||
output = append(output, [2]int{element, nextElement})
|
||||
S.POP()
|
||||
metrics.AddMovesCost()
|
||||
|
||||
Reference in New Issue
Block a user