MCPcopy Create free account
hub / github.com/codecombat/codecombat / __range__

Function __range__

app/views/artisans/StudentSolutionsView.js:309–317  ·  view source on GitHub ↗
(left, right, inclusive)

Source from the content-addressed store, hash-verified

307})())
308
309function __range__ (left, right, inclusive) {
310 const range = []
311 const ascending = left < right
312 const end = !inclusive ? right : ascending ? right + 1 : right - 1
313 for (let i = left; ascending ? i < end : i > end; ascending ? i++ : i--) {
314 range.push(i)
315 }
316 return range
317}

Callers 1

hashStringMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected