| |
SPL Procedure - Define function having return value
1. Define function without argument
- You can define function by using "procedure - end" commands.
| |
clear
print "Cur date is " + func1()
procedure func1
return Util.Now()
end
| |
|
|
|
|
- Executed result is as follows.
2. Define function having argument
- You can define function having arguments as follows.
| |
clear
print "Sum is " + func2(100, 200)
procedure func2(a, b)
return a + b
end
| |
|
- Executed result is as follows.
|