In my experience, refactoring code is not the best way to move forward and improve in case you are just starting to learn programming. Instead of refactoring, try to think of what could have been done in a better, more efficient way and allow your mistakes to teach you a lesson that you can use to your advantage in your future projects.
I would suggest starting a brand new project where apart from tackling new problems that arise and diving into new concepts that the project requires, you could concentrate on avoiding mistakes that you made in the past and eventually produce better, cleaner and more scalable code.
With every new project you work on, you face new problems, explore new concepts and, most importantly, make tons of mistakes, which are crucial for improvement.
This may not exactly be an answer to your question, but I felt like it was worth sharing, since I was asking myself the same question in my early years of programming.
Hope this helps and wish you all the best!
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…