Something that bothers me,
When connecting a button to an arduino, I understand that a pull up resistor makes sure there won't be an open end when the button is unpressed which will might cause a bad reading, but on the same time it seems that if there will be no resistor, the bigger problem will be a short between the 5 volts going to the button, to the ground (when the button is pressed), am I right?
Thank you for the answer, but I am trying to understand the logic behind it (without using the internal pull up resistor), in the circuit in the picture, does the R1 has to be there to prevent short? (in case of no use the internal arduino's pullup resistor)
something else about the same case, In the attached diagram, when the button is unpressed, I saw one website that says the arduino would get a 5v but wouldnt it be less than 5 volts because of the voltage drop on the resistor?
Let's say R1 was 10k.
The input resistance for the input gate is extremely large so the input current is next to nothing.
Therefore, almost zero current X 10k gives almost zero voltage across the 10k (R1).