Talk:Luhn algorithm: Difference between revisions

Content deleted Content added
Roger Hui (talk | contribs)
Roger Hui (talk | contribs)
Line 268:
Luhnc←{10|-+/,0 10⊤⍵×⌽(≢⍵)⍴2 1} ⍝ calculate the check digit
Luhnv←{(¯1↑⍵)≡Luhnc ¯1↓⍵} ⍝ verify the check digit
 
x← 7 9 9 2 7 3 9 8 7 1
Luhnc x
3
Luhnv x,3
1
</pre>
[[User:Roger Hui|Roger Hui]] ([[User talk:Roger Hui|talk]]) 10:2233, 16 October 2016 (UTC)