The computer doesn't think. It reads a recipe and follows it literally, even when the recipe is wrong.
Imagine you order food through an app, the price on screen is one thing, and a different amount gets charged to your card. It's not magic, and it's not 'the computer glitched'. Someone wrote a line of text that tells the system what to do in exactly this situation - and the system executed it literally. The line was wrong - the result was wrong. The computer doesn't judge whether it seems reasonable. It has no opinion.
Code works like a recipe followed literally by a cook with no judgment of their own. If the recipe says 'pour in the salt', he pours in the entire salt shaker, because nobody wrote 'as much as needed'. People read recipes and sense when something sounds excessive. The computer doesn't sense anything. It executes exactly what's written, even when it's absurd.
That's where 'bugs' come from - the word programmers use for errors in code. A bug isn't the computer getting something wrong on its own. A bug is the moment a person wrote an instruction different from what they actually meant to achieve. The computer executed what was written perfectly. It's just that what was written wasn't the right thing.
An app - whatever it is, your banking app, the restaurant map, the thing you shop through - is built from this text. All of that text together is called the codebase. It's not one page. It's not one recipe. It's an entire cookbook, written by many people, with recipes that reference each other. Change something in one recipe, and the effect can pop up in a completely different part of the book - because the cook will still follow it literally.
This is where it's decided
When you hear 'there's a bug', don't think of a broken computer. Think of a cook following a recipe too literally, because the recipe didn't explain precisely enough what its author wanted.
I work right on this edge every day. When I build a system, I don't write magic, I write recipes, and I know the cook on the other side will do exactly what I wrote, even when I haven't thought of everything. So trust in software isn't trust in the machine. It's trust in how carefully the recipe was written.