In reply to szy0014:
Actually, extending from the same idea, I think for 2 hot bits we can modify the constraint as follows:
constraint c_numb{
(numb & (numb-1) & (numb-2)) == 0;
}
So, I agree that this could be used in general.
But still please let me know if it is possible using the function. I curious to see if there is a solution for that.
Thanks