usbrubberducky-payloads/payloads/examples/Operators/Operators-example1.txt

1 line
743 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

REM Assign $FOO to 42
VAR $FOO = 42
REM The variable is now 42.
REM Lets add it by 1.
$FOO = ( $FOO + 1 )
REM The variable is now 43: the sum of 42 and 1.
REM Lets subtract it by 1.
$FOO = ( $FOO - 1 )
REM The variable is now 42 (again):
REM the difference of 42 and 1.
REM Lets multiply it by 2.
$FOO = ( $FOO * 2 )
REM The variable is now 84:
REM the product of 42 and 2.
REM Lets divide it by 2.
$FOO = ( $FOO / 2 )
REM The variable is now 42 (again):
REM the quotient of 82 and 2.
REM Lets modulus it by 4.
$FOO = ( $FOO % 4 )
REM The variable is now 2:
REM the signed remainder of 42 and 4.
REM Lets raise it to the power of 6.
$FOO = ( $FOO ^ 6 )
REM Our variable is now 64:
REM the exponent of 2 and 6.