Write the letter after the last letter in the row with a specific character

Asked 2 years ago, Updated 2 years ago, 19 views

I'm a beginner trying to use Python.

You are about to modify the txt file with Python.

For example,

.... Previous row

2019 Statistics (Statistics Office) 25

—- Subsequent rows

If it says so,

2019 -> \par \hfill{\scriptsize 2019 Change to

25 -> 25 }

Here, 25 is the last letter of the line. What should I do with the program I change to?

And not only in 2019, but from 1980 to 2019 That is,

1990 Statistics ... .. 1991 Statistics ... ..

How do I deal with the lights collectively?

python

2022-09-22 18:16

1 Answers

It's like a regular expression question, not Python. Because the txt file modification itself can be found and replaced with Sublime Text or VS Code as much as you want, but how to modify it eventually goes to the regular expression problem.

Can you open the regular expression link and learn after that?


2022-09-22 18:16

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.