How to use GMP

GMP(GNU Multiple Precision Arithmetic Library) is a portable library written in C for arbitrary precision arithmetic on integers, rational numbers, and floating-point numbers. It aims to provide the fastest possible arithmetic for all applications that need high precision. There is no theoretical...

Bits of tricks

GCC built in functions GCC provides a large number of built-in functions. Some of them are quite efficient and extremely convenient in practice. __builtin_ctz(x) count trailing zeros in x __builtin_ctzll(x) count trailing zeros in x Note: the result is undefined if x is zero. __builtin_popco...

Recent Posts