comefrom: <doocs>1736.Latest Time by Replacing Hidden Digits_1.py
code: def maximumTime( time: str) -> str:
      t = list(time)
      if t[0] == '?':
          t[0] = '1' if '4' <= t[1] <= '9' else '2'
      if t[1] == '?':
          t[1] = '3' if t[0] == '2' else '9'
      if t[3] == '?':
          t[3] = '5'
      if t[4] == '?':
          t[4] = '9'
      return ''.join(t)
masked: def sample_funcname ( var_0 : str ) -> str :
      var_3 = list ( var_0 )
      if var_3 [ 0 ] == '?' :
          var_3 [ 0 ] = '1' if '4' <= var_3 [ 1 ] <= '9' else '2'
      if var_3 [ 1 ] == '?' :
          var_3 [ 1 ] = '3' if var_3 [ 0 ] == '2' else '9'
      if var_3 [ 3 ] == '?' :
          var_3 [ 3 ] = '5'
      if var_3 [ 4 ] == '?' :
          var_3 [ 4 ] = '9'
      return ''.join ( var_3 )
  