(a) Whenever the commission of any act or the omission to act under certain circumstances constitutes both a violation of state law and a violation of municipal law, notwithstanding the fact that different penalties are provided, no person shall be prosecuted in both a state court and a municipal court for the same offense.
(b) A dismissal on the merits, acquittal or conviction of the offense in one (1) court, pleaded and shown, shall be a bar to prosecution for the offense in the other court.