func (x Target) Cmp(y Target) int {
	return x.Int().Cmp(y.Int())
}
Cmp compares the difficulties of two targets. Note that the difficulty is
the inverse of the target. The results are as follows:
-1 if x <  y
0 if x == y
+1 if x >  y
package types
import (
	"errors"
	"math/big"
	"github.com/NebulousLabs/Sia/build"
	"github.com/NebulousLabs/Sia/crypto"
)
type (
	Target crypto.Hash
)
var (
	ErrNegativeTarget = errors.New("negative value used when converting to target")
)
func (x Target) AddDifficulties(y Target) (t Target) {
	sumDifficulty := new(big.Rat).Add(x.Inverse(), y.Inverse())
	return RatToTarget(new(big.Rat).Inv(sumDifficulty))
}