Answer: eating and sex.
Almost everyone just figures these things out. That is because we were biologically designed to. I'm a nutritionist so I'm most qualified to talk about the first of these two items.
When humans were first created, grocery stores and refrigerators did not exist. Food was foraged. Survival instincts told humans that they needed to have enough energy (measured in calories) to survive. So the natural tendency to reach for the highest calorie option was born (note: vegetables are not a high-calorie food). A 2020 study looked at what foods participants could more readily relocate in a computer-based spatial map using visual and small memory cues. It was consistently seen that they had an enhanced memory for locating the high-calorie foods vs low-calorie foods.
High-calorie foods may come in the form of meat or dairy if you consume animal products. Plant-based high caloric foods are usually grains or possibly potatoes. Of course, processed foods of all sorts are often calorie-dense.
Think about it, if you’re really hungry do you crave a salad? Or does the nearest fast food restaurant sound appealing? My guess is you likely have experienced having that inner desire for the higher-calorie food that is easiest to access. Seeking the most reward for the least effort is in our biology. To move beyond that will take work and effort. But the effort is worth the reward! No more do we need to forage for our food. We can get all the calories we need to make enough energy from healthy foods like plants.
If you need help getting more plants into your diet check out my Plantiful Plate meal plan subscription. It's just $20 and you get 3 recipes (plus bonus recipes), a grocery shopping list, and a support group with access to a nutritionist - every week! Subscribe at: www.loveandplants.com/plantiful-plate