Is there something existing in python that can convert an increasing list of integers into a range list
E.g. given the set {0, 1, 2, 3, 4, 7, 8, 9, 11} I want to get
Nothing built-in, or in any libraries that I know of. Not very helpful, I know, but I've never come across anything like what you want.
Here are some ideas for your program atleast (in C++, but it can give you some other ideas):
Converting sets of integers into ranges