Mode: On-Campus OA Date: 2026-11-02
You are given a directed weighted graph with N nodes and M edges. Each edge connects
N
M
…
Given an array of values, determine the required result under the following conditions.
Input: [4, 8, 15, 16, 23, 42]
Output: 3
Constraints: 1 ≤ n ≤ 10⁵
Unlock the full statement, examples, constraints, and solution guidance.
Therefore, the answer is 1.
1
Run code to see test results
HiLabs • 114 views
HiLabs • 108 views
HiLabs • 330 views