📄 modinverse.vbs
字号:
'----------------------------------------------------------
' Modular Inverse Calculation Script
'-----------------------------------
'
' This VBScript code shows how to calculate the modular
' inverse of a number.
'
' The data in this example is taken from Handbook of
' Applied Cryptography (8.2, p287), by A. Menezes, P. van
' Oorschot, and S. Vanstone, CRC Press, 1996.
'
' Summary: compute b such that a*b mod n = 1.
'
' a = 38 13 1f
'
' n = 5b ab f8
'
' The result should be:
' b = 06 71 2f
'
'----------------------------------------------------------
Dim strHexA, strHexB, strHexN
strHexA = "38 13 1f"
strHexN = "5b ab f8"
strHexB = Hpmbmath.ModInverse(strHexA, strHexN)
Hpmbmath.Output("Result = " + strHexB)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -