My task passed testing through trial and error, but, I thought we cannot make a new instance of a static class. Can someone explain how this works in this exercise or refer me to some resource that explains this?
hidden #10513713
Level 9
Instantiating a static class
Resolved
Comments (5)
- Popular
- New
- Old
You must be signed in to leave a comment
Guadalupe Gagnon
5 March 2020, 18:08solution
I think you may be confusing abstract classes and static classes. Either way this is an advanced, and very powerful, topic of object orientated programming. I really wouldn't recommend you focusing on trying to understand these concepts that Codegym is introducing you to little by little because they are starting to paint a much larger picture with the individual pieces. You can look up object oriented principles about abstraction, encapsulation, and inheritance if you want to do some research in regards to your question.
Trial and error is the quintessential way of learning how to program. There are many memes about this. This one is of my favorites:
![]()

+3
Guadalupe Gagnon
5 March 2020, 18:11
(feel free to ask questions though)
0
Anonymous #10560641
16 April 2020, 23:14
If you start reading Bruce Eckel's "Thinking in Java" (which can be found for free on the internet in .pdf format), that starts on instantiation, abstraction and inheritance. Quite interesting even if I don't understand it!
0
John W Lolo
13 May 2020, 03:02
I disagree with your premise that "trial and error [is] the quintessential way to learn anything. Although that may cater to a minority learning style, solid instruction and proper practice works for the majority.
0
Guadalupe Gagnon
13 May 2020, 15:56
@Vicky I have the book and read it front to back. A great read for anyone and one i highly recommend.
0