Solution
Solution
print(.05 + 0*.5)
print(.05 + .01*.5)
print(.05 + .05*.5)
Source Code
As you can see, the risk of default drives up the yield to maturity a bond needs to have. A risk-free bond would have 5% yield to maturity, but a CCC bond would have a 7.5% yield to maturity.
You can also get the expected yield to maturity with the CAPM equation. We won’t walk through an example, but you would get the beta for the bond, and then plug it into the CAPM equation.