I'm trained as a barista. We had months of training on this.
Making a really really good espresso, piccolini, babyccino, cappuccino, latte or hot chocolate is not easy. It's far from just putting a mug under the machine and hitting go. There's a lot more considerations, here are just some of them:
Is it first thing in the morning? Espresso machines take a little while to warm up and are slower first thing.
Are the grounds weighing the correct amount? A shot has an acceptable weight of grounds. Any more and your coffee/water ratio will be off and it will taste horrid. Grind times need adjusting. Think of it as the difference between water running through gravel and sand.
Are the grounds properly tamped (pressed down)? This also affects the way the water runs through them.
Is the espresso shot pulling through in the correct amount of time? Seconds out and your coffee will taste like sludge.
Have the grounds been allowed to sit under the portafilter? This will burn them.
Has the milk wand been cleaned properly between uses?
Is it with flat or cappuccino (frothy) milk? Has the milk been taken to the correct temperature? If it's soy milk has it been taken to the correct (lower) temperature or allowed to curdle or burn?
How good is the barista's knowledge of the coffee they serve? Can they tell you where the beans in the blend come from? Is it rainforest alliance certified? Fairtrade? Organic? Arabica or Robusta beans? How long has the espresso shot sat there for? How clean are the milk jugs and milk thermometers? Are the beans from a smaller roastery, these can be greener and less roasted as opposed to most of the major chains which roast more in order to ensure uniformity of flavour?
Now bear in mind. As a trained barista, you're thinking about all of this with every coffee you make in order to ensure the best possible experience for the person drinking it.
Can you honestly tell me that most people who go to a coffee shop think about any of this?
This is science, an artisan skill and frankly it's insulting to suggest that just anyone could walk into a coffee shop and make a fantastic espresso.