code: def strnumcollate(s1, s2):
      # return -1 if s1<s2, +1 if s1>s2 else 0
  
      # split values into two parts - the head and the numeric tail
      values = [s1, s2]
      for vn, v in enumerate(values):
          for i in range(len(v), 0, -1):
              if v[i - 1] not in "01234567890":
                  break
          try:
              v = (v[:i], int(v[i:]))
          except ValueError:
              v = (v[:i], None)
          values[vn] = v
      # compare
      if values[0] < values[1]:
          return -1
      if values[0] > values[1]:
          return 1
      return 0
  
imports: from __future__ import print_function
  import sys
  import os
  import time
  import apsw
  import random
label_desc: Use image node_id 5 for calling a global function with example usage: strnumcollate(s1, s2) and returns: int, unknown, int