Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- PROCEDURE Cnas(NSS is string)
- //var
- sCle is string
- I, X1, X2, N are int
- X1 = 0
- X2 = 0
- FOR I = 1 TO 10
- N = Val(NSS[I])
- IF IsOdd(I) THEN
- X2 = X2 + N * 2
- ELSE
- X1 = X1 + N
- END
- sCle = NumToString(99 - (X1 + X2),"02d")
- END
- RESULT sCle
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement