The contribution of fermionic seesaws to the anomalous magnetic moment of leptons