Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
mohamedkhallouq
GitHub Repository: mohamedkhallouq/content
Path: blob/main/files/en-us/webassembly/reference/numeric/and/index.md
6516 views
---
title: AND slug: WebAssembly/Reference/Numeric/AND
---

{{WebAssemblySidebar}}

The and instructions, are used for performing a bitwise AND, similar to the & operator in other languages.

{{EmbedInteractiveExample("pages/wat/and.html", "tabbed-taller")}}

Syntax

;; load two numbers onto the stack i32.const 5 ;; 00000101 i32.const 3 ;; 00000011 ;; perform a bitwise AND i32.and ;; the top item on the stack will now be 1 (00000001)
InstructionBinary opcode
i32.and0x71
i64.and0x83