kids encyclopedia robot

Prefix notation facts for kids

Kids Encyclopedia Facts
Prefix-dia.png
Prefix notation
Infix notation
Postfix notation

Prefix notation is a special way to write down math problems and formulas. It's also known as Polish notation. A smart person named Jan Łukasiewicz invented it in 1920. He wanted to make writing logic equations simpler.

When you use prefix notation, you don't need to use parentheses or other grouping symbols. This can make math expressions look much cleaner!

What is Prefix Notation?

In prefix notation, the math operation (like adding or subtracting) always comes before the numbers it works on.

For example, if you want to add 2 and 3, you would normally write:

  • 2 + 3

But in prefix notation, you write the plus sign first:

  • + 2 3

Let's try another one. If you want to subtract 5 from 10, you would write:

  • - 10 5

This way of writing things might seem a bit strange at first, but it has some cool benefits!

How Does it Work Without Parentheses?

The order of the numbers and operations tells you exactly what to do. Because the operation comes first, you always know what numbers it applies to.

Imagine you have this problem:

  • + * 2 3 4

How do you solve it? 1. First, find the innermost operation. Here, it's `* 2 3`. This means "multiply 2 by 3," which equals 6. 2. Now, replace `* 2 3` with its answer: `+ 6 4`. 3. Finally, `+ 6 4` means "add 6 and 4," which equals 10.

So, `+ * 2 3 4` is the same as `(2 * 3) + 4` in normal math.

Where is Prefix Notation Used?

You might find prefix notation in some CASIO calculators. It's also used in certain programming languages, like LISP. These languages use prefix notation because it can make it easier for computers to understand and process math problems.

kids search engine
Prefix notation Facts for Kids. Kiddle Encyclopedia.