I'm not arguing against exercise, but with GLP-1 drugs, you literally do not need to exercise to lose weight.
In my late 20s, I lost about 60 lbs of weight, almost entirely through a small number of dietary changes--zero beverages other than water and unsweetened coffee, zero french fries, zero bagged snack foods, zero going out to eat for lunch. I also practiced intermittent fasting, sporadically, for 24 hours. I didn't change my exercising at all.
Now, since I lost the weight, I've taken up more exercise (bike, jog, lift) and I've maintained a steady weight for almost 15 years now.
Bodybuilders say "abs are made in the kitchen, not the gym." They've got a point.