So I am having trouble thinking of a way to get different ranges from one list. The code is as follows:
data = [101, 102, 103, 104, 105, 106, 108, 109, 110, 111, 112, 115, 116, 117, 118, 119, 121]
f_range = []
The output from the print()
needs to look something like:
101-106, 108-112, 115-119, 121
I would need to group these be sequential increasing order.