Path: blob/main/files/en-us/webassembly/reference/numeric/subtraction/index.md
6517 views
------{{WebAssemblySidebar}}
The sub instructions, short for subtraction, are used for subtracting one number from another number, similar to the - operator in other languages.
{{EmbedInteractiveExample("pages/wat/sub.html", "tabbed-taller")}}
Syntax
| Instruction | Binary opcode |
|---|---|
i32.sub | 0x6b |
i64.sub | 0x7d |
f32.sub | 0x93 |
f64.sub | 0xa1 |