The fast way to farm them is by placing a mushroom on podzol or mycelium and using bonemeal on it. Then you get quite a few mushrooms when breaking the big one.
Carrots can sometimes be found growing in farm plots within naturally-generated Villages. They may also be dropped (2.5% chance) by Zombies when killed.