input: Write a python function to convert a binary string to a decimal number.
  assert bin_to_dec('10101') == 21
  assert bin_to_dec('110') == 6
  assert bin_to_dec('1001') == 9
  assert bin_to_dec('11111111') == 255
output: def bin_to_dec(binary_str):
      return int(binary_str, 2)