MCPcopy Create free account
hub / github.com/VanjaRo/LeetCode / minValNode

Function minValNode

tasks/23.go:61–72  ·  view source on GitHub ↗
(fNode, sNode *ListNode)

Source from the content-addressed store, hash-verified

59}
60
61func minValNode(fNode, sNode *ListNode) (*ListNode, bool) {
62 if sNode == nil {
63 return fNode, true
64 }
65 if fNode == nil {
66 return sNode, false
67 }
68 if sNode.Val < fNode.Val {
69 return sNode, false
70 }
71 return fNode, true
72}

Callers 1

mergeTwoListsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected