Set the grill to high heat, or preheat a conventional oven to 375°F. The grill gives stronger browning, while the oven produces a gentler finish.
Warm the butter in a small saucepan over medium heat until melted, stir in the minced garlic for 20 seconds, then remove the pan from the heat and keep the butter liquid. The garlic should release a fragrant aroma without turning dark.
Stir the garlic powder, paprika, salt, and pepper together in a small bowl. A uniform color helps show that the spices are evenly combined.
Coat the cut corn with olive oil in a large bowl, then add the seasoning in stages while turning the pieces between additions. Look for an even coating on the kernels and exposed cob, where some of the rub will collect.
For grilling, cook the ribs with the kernels against the grate for 8 minutes or until charred patches appear, then turn them onto each cut side for 1 minute per side. You may hear light popping as the kernels brown and see the strips begin to curve.
For oven cooking instead, arrange the ribs kernel-side up on a baking sheet and bake for 25 to 30 minutes. The kernels should become tender, although the pieces may curve less and show little char.
Return the hot cooked corn to the large bowl and turn it through the warm garlic butter. The melted butter should coat the ribs with a glossy finish and release a fresh garlic aroma.
Arrange the ribs on a plate and add the optional chopped parsley or cilantro if using. The kernels should feel tender with slight give when bitten, while the cob remains firm.