MCPcopy Create free account
hub / github.com/hydro-dev/Hydro / getScore

Function getScore

packages/common/subtask.ts:68–75  ·  view source on GitHub ↗
(totalScore: number, count: number)

Source from the content-addressed store, hash-verified

66];
67
68function* getScore(totalScore: number, count: number) {
69 const base = Math.floor(totalScore / count);
70 const extra = count - (totalScore % count);
71 for (let i = 0; i < count; i++) {
72 if (i >= extra) yield base + 1;
73 else yield base;
74 }
75}
76
77interface ParsedCase {
78 id?: number;

Callers 1

normalizeSubtasksFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected