@@ -0,0 +1,650 @@
+#Kunal Gautam%0A#Codewars : @Kunalpod%0A#Problem name: Range Extraction%0A#Problem level: 4 kyu%0A%0Adef create_string(final, series):%0A    if len(series) %3C= 2:%0A        final.append(','.join(%5Bstr(x) for x in series%5D))%0A    else:%0A        final.append('-'.join(%5Bstr(series%5B0%5D), str(series%5B-1%5D)%5D))%0A    return final    %0A%0Adef solution(args):%0A    series = %5Bargs%5B0%5D%5D;    final = %5B%5D%0A    for i in range(1, len(args)):%0A        if args%5Bi%5D - args%5Bi-1%5D == 1:%0A            series.append(args%5Bi%5D)%0A        else:%0A            final = create_string(final, series)%0A            series = %5Bargs%5Bi%5D%5D%0A    if series:%0A        final = create_string(final, series)%0A    return ','.join(final)%0A

Create range_extraction.py