Quadratic, I believe. You create a sequence of strings of length 1, 2, 3, ..., n, which is about n^2/2. Of course it isn't that simple (memory alignment and all that), but it doesn't look exponential.
Quadratic, I believe. You create a sequence of strings of length 1, 2, 3, ..., n, which is about n^2/2. Of course it isn't that simple (memory alignment and all that), but it doesn't look exponential.