This forum is for my family to discuss and talk about whatever. Anyone else looking at it, I'd prefer you didn't look but if I can't stop you, then I can't stop you. Please don't if I can't.

You are not connected. Please login or register

# Mathematics: Toggle

Message [Page 1 of 1]

#### EccentricPhilosopher

Here is an interesting puzzle. I didn't make this up, I found it somewhere, but it's an interesting puzzle. Using the variable x, what formula can be used that if x is zero, it would become one, but if it's one, it would become zero?

Example: If the formula was x = x + 1, then x would become one if it was zero. This doesn't work though because if it was one, then it'd become two. There may be multiple answers, so any that work wins.

#### hazzmta

y = 1 - x

proof:
if x = 0, y = 1 - 0, y = 1
if x = 1, y = 1 - 1, y = 0

QED

in digital logic, this is a "NOT" gate, or an inverter.

Correct!

#### Sponsored content

Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum