CodeGym /Courses /Java Multithreading /Practice using static nested classes

Practice using static nested classes

Java Multithreading
Level 3 , Lesson 6
Available

"Hi, Amigo!"

"Yeah, tasks, I know, I know. By the way, Diego, you make great tasks."

"Thanks for finally noticing. Here are some more:"

7
Task
Java Multithreading, level 3, lesson 6
Locked
How do I choose the right one?
In the main method, assign an instance of the TEST class to the Object obj variable. Don't change anything except the main method.
7
Task
Java Multithreading, level 3, lesson 6
Locked
Refactoring, nested classes
Refactor the Solution class: put all the constants in the nested public Constants class. Prevent the Constants class from being inherited.
Comments (7)
TO VIEW ALL COMMENTS OR TO MAKE A COMMENT,
GO TO FULL VERSION
2 April 2021
Thanks, Diego! That was easy.
Shilpa nori Level 34, Rochester, United States
6 March 2021
This easy tasks are very confusing 🤨🙂
Fadi Alsaidi Level 34, Carrollton, TX, USA
29 November 2020
this is a codegym article about refactoring https://codegym.cc/groups/posts/196-how-refactoring-works-in-java
JianQiu Hwang Level 35, Washington
12 June 2020
The "Introduce Constant"(Ctrl+Alt+C) is helpful for "Refactoring, nested classes"
MaGaby2280 Level 41, Guatemala City, Guatemala
13 July 2020
Thank you!!! Great tip!!!
Switch/Cypher Level 25, Bexleyheath, United Kingdom
29 October 2020
Yes. Exactly this. And you might need Ctrl + T to refactor individual entries as well.
Jurij Thmsn Level 29, Flensburg, Germany
14 October 2021
Thanks for the tip. I used Refactor - Introduce Constant, which worked -but I had to move all the constants manually into the "Constants" class and add Constants.BLA_BLA before every occurence of the constant manually. Is there an easier wy to do this?