Noob here with simple question. I'm building a DFA for a homework problem. I have to make a DFA where the binary representation of a number is divisble by N.
As a sample input of 5, I'm not sure if I need to use 101 or 00000101? Because that changes the state diagram based on which base I use.
I am not sure to understand your problem in the case $N = 5$. If I am not wrong, the automaton below accepts exactly the binary representations of a number divisible by $5$, including those leading with an arbitrary number of zeros, like $101, 0101, 00101, 000101$, etc.
$\hskip 100pt$