How do I increase numbers by one
-
How do I increase numbers by one for this set of numbers? :-
<sup>[0]</sup> <sup>[1]</sup> <sup>[2]</sup> <sup>[3]</sup> <sup>[4]</sup> <sup>[5]</sup> <sup>[6]</sup> <sup>[7[</sup> <sup>[8]</sup> <sup>[9]</sup> <sup>[10]</sup> <sup>[11]</sup>
The output should be:-
<sup>[1]</sup> <sup>[2]</sup> <sup>[3]</sup> <sup>[4]</sup> <sup>[5]</sup> <sup>[6]</sup> <sup>[7[</sup> <sup>[8]</sup> <sup>[9]</sup> <sup>[10]</sup> <sup>[11]</sup> <sup>[12]</sup>
-
https://community.notepad-plus-plus.org/topic/23170/faq-can-i-do-a-mathematical-replacement
You’ve been here long enough to know to check the FAQs. “ADD A VALUE TO EACH MATCH” is literally the first example for the PythonScript solutions in that FAQ.
-
@PeterJones Okay, thank you.
I think this will work for me:-
REPLACE WITH A SIMPLE COUNTER (I.E., RENUMBERING)
Plugins > Columns++ > Search…
Find what : <sup>[(\d+)
Replace with : <sup>[(?=match)
I will try it tomorrow
For those who arrive at this webpage by searching online, let me tell you that I am expecting a result like this:-<sup>[1]</sup> <sup>[2]</sup> <sup>[3]</sup> <sup>[4]</sup> <sup>[5]</sup> <sup>[6]</sup> <sup>[7[</sup> <sup>[8]</sup> <sup>[9]</sup> <sup>[10]</sup> <sup>[11]</sup> <sup>[12]</sup>
-
@PeterJones I was finally able to increase the numbers by one, using the methods you elucidated at, “How to install and run a script in Python Script”. Thanks a lot!