Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
Math.ClearBit
Clears a bit in a 64-bit number.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
Math | 15.3 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
MBS( "Math.ClearBit"; Value; Bit ) More
Parameters
Parameter | Description | Example |
---|---|---|
Value | The current value. | 0 |
Bit | The bit number to set. From 0 to 63. |
0 |
Result
Returns OK or error.
Description
Clears a bit in a 64-bit number.Examples
Clear 1st bit, which removes 1 from 5:
MBS( "Math.ClearBit"; 5; 0 )
Example result: 4
Clear 2nd bit, which does nothing here:
MBS( "Math.ClearBit"; 5; 1 )
Example result: 5
Clear 3rd bit, which removes 4:
MBS( "Math.ClearBit"; 5; 2 )
Example result: 1
Release notes
- Version 15.3
- Added Math.SetBit, Math.ClearBit and Math.GetBit functions.
Blog Entries
This function is free to use.
Created 21st May 2025, last changed 21st May 2025
