Summarize:

Melons can be found in jungles biomes, and savanna villages. Pumpkins can be found in any biome that has grass block with no plants growing out of it. You can also find melons and pumpkins in stem farm rooms of woodland mansions. To obtain melon or pumpkin seeds, break the melons or pumpkins open using your hand or a sword and walk over the seeds to collect them. You can craft a hoe using a crafting table. Have to sticks and two blocks or bars of the material of your choice, and select them, or place them in the crafting grid in the following positions: Place a stick in the middle space, and the bottom middle space. Sticks can be crafted from wood plank blocks, which can be crafted from wood. Place a wood plank block, stone block, iron bar, or diamond in the upper-middle space, and the upper-left space. Click and drag the hoe to your inventory. Equip the hoe and use it on dirt or grass to till the soil. To equip the hoe, open your inventory and place it in your tool bar. Press the number that corresponds to the toolbar space on your keyboard, or press the right and left shoulder buttons on the controller to highlight the different toolbar spaces. Place the reticle on a grass or dirt block and right-click, or press the left trigger button on the controller to till the soil. Equip the melon or pumpkin seeds by opening your inventory and placing them in your toolbar. Highlight the space in your toolbar to equip the seeds. Then place the reticle on a tilled soil block and right-click or press the left trigger button on the controller to plant the seeds. The melons or pumpkins are ready to be harvested when there is a melon or pumpkin block next to the plant.
Obtain melons or pumpkin seeds. Craft a hoe. Till the soil. Plant the melons or pumpkins. Wait.