How to store corn on the cob
Best place: the fridge. USDA gives corn on the cob a fridge time (1 to 2 days, from the package date) and no pantry time, so it belongs in the fridge as soon as you get home. The freezer gives 8 months.

No guideline
1 to 2 days
from the package date
8 months
best quality within
How to tell corn on the cob has gone bad
General signs for produce: fresh vegetables, the group USDA lists corn on the cob under.
- Slimy, wet leaves on greens that were crisp before
- Soft or mushy spots on vegetables that were firm
- Sprouting or wrinkled skin on potatoes and onions
- Mould, often white or fuzzy, near the stem or cut end
- Sour or off smell replacing a vegetable's usual earthy scent
More on produce: fresh vegetables. The times above are quality guidelines, not safety limits; food that shows these signs goes out regardless of the date.
Storage habits that make the difference
Store leafy greens loosely wrapped in the crisper drawer, ideally with a paper towel to absorb extra moisture. Keep potatoes, onions and garlic in a cool, dark, dry place outside the fridge, and store potatoes away from onions since they spoil each other faster. Trim and wash vegetables just before cooking.
Looking for one kind of corn on the cob?
How to store other produce: fresh vegetables
Source: USDA FSIS FoodKeeper dataset (public domain). How we decode the data.