gmp_libmpn_popcount Method |
Namespace: Math.Gmp.Native
public static mp_bitcnt_t mpn_popcount( mp_ptr s1p, mp_size_t n )
Public Shared Function mpn_popcount ( s1p As mp_ptr, n As mp_size_t ) As mp_bitcnt_t
public: static mp_bitcnt_t mpn_popcount( mp_ptr^ s1p, mp_size_t n )
static member mpn_popcount : s1p : mp_ptr * n : mp_size_t -> mp_bitcnt_t
// Create multi-precision operand. mp_ptr s1p = new mp_ptr(new uint[] { 0x0000001, 0x00000001 }); // Assert result of operation. Assert.IsTrue(gmp_lib.mpn_popcount(s1p, s1p.Size) == 2); // Release unmanaged memory. gmp_lib.free(s1p);
' Create multi-precision operand. Dim s1p As New mp_ptr(New UInteger() { &H1, &H1}) ' Assert result of operation. Assert.IsTrue(gmp_lib.mpn_popcount(s1p, s1p.Size) = 2) ' Release unmanaged memory. gmp_lib.free(s1p)
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.