There isn't just one way to do something

In software development, there are usually multiple ways to achieve the same result.

There is no one "right" answer.

You can make a website look the same if you write the CSS by hand or use a framework.

When writing backend code, you could use design patterns and follow good clean code practices or not.

How you approach a solution depends on your experience and perspective, but one approach isn't wrong when compared to another if they achieve the same result.

Here's the thing

This is why I like pair and mob programming.

Everyone involved can discuss, plan and contribute to a solution in real-time.

You're more likely to get a better and more thought-out and robust solution from the collective perspective and experience compared to working individually, with the added benefit that more than one person understands the solution if it needs to be extended or changed in the future.