Skip to content

Commit cb336ed

Browse files
committed
✨ lc b150-1
1 parent 1a45747 commit cb336ed

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

B0150_Problem_1.bqn

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# For up to date code:
2+
# https://github.com/codereport/bqn-code/blob/main/leetcode/b150-1.bqn
3+
4+
# Link: https://leetcode.com/problems/sum-of-good-numbers
5+
6+
u•Import "/home/cph/bqn-test/test.bqn"
7+
8+
SumOfGoodNumbers ← { +´𝕩×∧´¨𝕩>¨(0≤∧≤(n-1))0,𝕩¨¨((+⋈-)𝕨)¨n𝕩 }
9+
10+
# Tests
11+
u.UnitTest (2 SumOfGoodNumbers1,3,2,1,5,4⟩) 12
12+
u.UnitTest (1 SumOfGoodNumbers2,1⟩) 2

0 commit comments

Comments
 (0)