ソースを参照

Swap syntaxes

master
JustAnotherArchivist 2年前
コミット
0b45f7b2ba
1個のファイルの変更4行の追加4行の削除
  1. +4
    -4
      alphabetseq

+ 4
- 4
alphabetseq ファイルの表示

@@ -32,9 +32,9 @@ def convert_start_stop(s, alphabet):
if ':' in s:
valalphabet, value = s.split(':')
if not valalphabet:
valalphabet = alphabet
valalphabet = '0123456789'
else:
valalphabet, value = '0123456789', s
valalphabet, value = alphabet, s
return alphabet_to_decimal(value, valalphabet)


@@ -60,6 +60,6 @@ if __name__ == '__main__':
print('Generates the sequence from START to STOP (inclusive) using ALPHABET', file = sys.stderr)
print('If STOP is omitted, it defaults to START, effectively making this a simple base transformation', file = sys.stderr)
print('START and STOP have values of the form [[VALALPHABET]:]VALUE.', file = sys.stderr)
print(' In the [VALALPHABET]:VALUE form, VALUE is expressed in terms of VALALPHABET, which defaults to ALPHABET if omitted.', file = sys.stderr)
print(' In the VALUE form, it is treated as a decimal number.', file = sys.stderr)
print(' In the [VALALPHABET]:VALUE form, VALUE is expressed in terms of VALALPHABET, which defaults to 0123456789 (i.e. decimal) if omitted.', file = sys.stderr)
print(' In the VALUE form, it is converted using ALPHABET.', file = sys.stderr)
sys.exit(1)

読み込み中…
キャンセル
保存