aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/algorithms/scripts/plot.py
diff options
context:
space:
mode:
Diffstat (limited to 'algorithms/scripts/plot.py')
-rwxr-xr-xalgorithms/scripts/plot.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/algorithms/scripts/plot.py b/algorithms/scripts/plot.py
index 25a87f7..61eeab1 100755
--- a/algorithms/scripts/plot.py
+++ b/algorithms/scripts/plot.py
@@ -40,7 +40,7 @@ def _parse_non_negative_integer(s):
try:
n = int(s)
except ValueError:
- raise argparse.ArgumentTypeError("must be a non-negative integer: " + str(s))
+ raise argparse.ArgumentTypeError(f"must be a non-negative integer: {s}")
if n < 0:
raise argparse.ArgumentTypeError("must be a non-negative integer")
return n
@@ -50,7 +50,7 @@ def _parse_positive_integer(s):
try:
n = int(s)
except ValueError:
- raise argparse.ArgumentTypeError("must be a positive integer: " + str(s))
+ raise argparse.ArgumentTypeError(f"must be a positive integer: {s}")
if n < 1:
raise argparse.ArgumentTypeError("must be a positive integer")
return n
@@ -60,11 +60,11 @@ def _parse_input_kind(s):
try:
return InputKind(s)
except ValueError:
- raise argparse.ArgumentTypeError("invalid input kind: " + str(s))
+ raise argparse.ArgumentTypeError(f"invalid input kind: {s}")
def _format_algorithm(codename):
- return "* {}: {}".format(codename, registry.get(codename).display_name)
+ return "* {codename}: {registry.get(codename).display_name}"
def _format_available_algorithms():