Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
A single line function to modify MOD for better pattern recognition....
#2
That's some complicated math stuff there!

Here's all one would ever need with MOD -- no matter which pattern they like best:

Code: (Select All)
For i = 10 To -10 Step -1
    Print i Mod 5, ModX(i, 5)
Next

Function ModX (num1, num2)
    ModX = ((num1 Mod num2) + num2) Mod num2
End Function
Reply


Messages In This Thread
RE: A single line function to modify MOD for better pattern recognition.... - by SMcNeill - 11-28-2022, 09:50 PM



Users browsing this thread: 1 Guest(s)