EV and FCFF

I know it’s one day before the exam but this question has me confused so if someone can shed some light , it would be helpful When we calculate the DCF value from FCFF , is that the Enterprise value of the firm. Intuitively speaking it should just be the value of equity and debt based on cash flows and should have no component of cash , since we don’t consider cash at all when doing a DCF of FCFF. EV = debt+market cap - cash. Hence , I think the value we get from the DCF of FCFF should be higher than EV e.g assume a firm has 50 in debt and 20 in cash. The DCF value of FCFF is 200. To calculate the target price of this company , I would subtract debt and add back cash, which is 200-50+20 = 170. Now , if someone needs to buy this company outright , they would pay the EV which would be 170 + 50 - 20 = 200. I come up with a value of EV which is the same as the DCF value of FCFF which I think should not be the case. Please help clear my thinking.