This is a pretty easy question, but I always get confused about pull ups and pull downs and stuff...
Imagine a simple ring-in "game buzzer" type setup (it's a close as I can describe it). Of course if I set a pin to input and put a switch on it and set another pin to output and put an LED on it, then I can check the state of the switch and turn the LED on and handle lock-out and stuff with code.
If you have more players than you have pins, you could use mux/demux and other digital logic. I understand that and those chips are cheap, but that isn't my question either :![]()
What if you wanted to have each pin handle the input and output, how would you wire it up and code it so that the loop() function scanned the pins set to input and when a button is pressed connected to an input pin, that pin could be set to output and light an LED on that pin (no other inputs would be considered until a reset button was pressed)?
Consider a simple case using two pins and a minimum number of components (pushbutton switch, LED, current limiting resistor). Can that be done? Can you connect a reverse biased LED in parallel with the switch or something?