I am very much a newbie when it comes to this stuff. I have to replace a broken light switch. When I took it apart, this is what the wiring looked like- one wire backwired and one using the side screw. What does this mean? Can i rewire it the same way with a new switch? Thank you in advance.
Yeah, it's real common inside junction boxes to have a lot of other stuff going on besides just your switch. Sometimes the wires that go to your switch also need to go elsewhere.
These multiple wires have to be spliced together somehow. A lazy/easy way to connect 2 wires and also a switch, is to use the switch as a splice block. In your case by attaching a wire to the screw and another to the backstab. Most of the current probably goes through the switch and out the other wire.
Like Ed Beal discusses, backstabs aren't very good. It may be better to go to a more traditional splicing technique, like a pigtail and wire nut. That will also make the wiring appear more logical.
The 2 wires are normally your hot coming in and then going on to another device the single wire is usually the switched hot to the light. I do not like back stabs; they usually hold up on lighting only circuits, but when the other wire is to a chain of outlets, all the power is going through that stab, a very tiny contact area. The stabs get hot and quit working and even melt switches but more often receptacles. I like to use a short piece of wire with a wirenut connecting the hot coming in and out and the short wire, or pigtail, to the switch. A lighting circuit for a room is usually fine if one must use backstabs, but I prefer the screw terminals even though they take longer to install myself and the electricians I work with use pigtails.
It could be a single hot going out to 2 different lights, also, but the first scenario is the most common.