Simplest physical setup for Arduino to switch between two modes?

Lets say I had a servo/light/whatever connected to an Arduino and I wanted to alternate it's speed/intensity/whatever between two modes/settings by flipping a switch. What would be the simplest way of physically implementing this?

So I think I would have a switch that when flipped on, sends a signal through a cable to one of the Arduino digital or analog pins. I code the Arduino to read that pin at the start of each loop and the presence of an active signal determines which mode to run.
So... could I have a switch just send 5v to one of the analog pins on the Arduino and have that as the switch signal?

Someone suggested using relays or MOSFETs, I'm not sure how that would work... if anyone has a quick rundown on the simplest method to do this that would be great.

So I think I would have a switch that when flipped on, sends a signal through a cable to one of the Arduino digital or analog pins.

That's what you need. Use the internal pullup resistor, and connect one leg of the switch to ground and the other leg to a digital pin.

The switch doesn't send a signal. You have to ask the pin which state it is in, based on the position of the switch.

I code the Arduino to read that pin at the start of each loop and the presence of an active signal determines which mode to run.

Yes.

So... could I have a switch just send 5v to one of the analog pins on the Arduino and have that as the switch signal?

No. Switches don't send signals. They allow, or block, the flow of current. The presence or absence of voltage on the pin is what you can read.

Someone suggested using relays or MOSFETs,

For what?

I'm not sure how that would work

Ask the person that suggested it to explain.

Wow thanks for the awesome snappy reply. I think I understand now, so the pin would be coded to detect the presence of voltage and the resistor limits the current to something extremely low or negligible because the amount of charge flowing isn't relevant, the voltage is (I assume the resistor also helps to stop too much current from flowing into the pin and damaging the electronics?).

So if I was sending either 5V or 3.3V to said pin, how many Ohms should my resistor be respectively? Obviously I couldn't use a resistor with an absurdly high amount like 4000k Ohms because then the current would be so small that the Arduino wouldn't detect anything on that pin, right?

No, the resistor is there to protect the switch and power supply. The input pin won't be damaged by any voltage within the range of the power supply connected to the micro's VCC pins (5.0v or 3.3v)

4000 ohms is actually lower than the usual pull up/down resistor. 10,000 ohms is more commonly used.

10,000 ohms is more commonly used.

Actually, once people get it through their thick heads that the Arduino has easy to use pullup resistors, no external resistors are used. Wiring switches using the internal pullup resistors is so much simpler.

Info on inputs and internal resistors here;