Pumpkins are cheaper but can be farmed quicker with a much cheaper tool but if you have 350k lying around I would suggest melons as they earn more money per hour.
Melons FTW, Been farming melons my whole ECC Life, therefore I bought a melon sword I love melons and always will.