Call a function In Python script

In Rhino script.
Sub ACAP()
MsgBox “Hello World”
End Sub
I can call this sub by command “CAP” as alias as
Rhino.AddAlias “CAP”, “_-RunScript (ACAP)”.
In Python script.
import rhinoscriptsyntax as rs
def ACAP():
rs.MessageBox(“Hello World”)
I don’t know how to call this fuction by by command “CAP” . Please help me!!!

Please start using tripple backticks around your code so it is actually readable.

To create commands using Python read the following guide: Creating Rhino Commands Using Python with Python