@heathborders@hachyderm.io avatar

heathborders

@heathborders@hachyderm.io

#Katie's Husband; #Ben and #Sam's Dad; iOS/Android at @Twitch. My toots don't represent my employer

This profile is from a federated server and may be incomplete. For a complete list of posts, browse on the original instance.

futurebird , to random
@futurebird@sauropods.win avatar

I'm looking for a FUN activity, or test question about Java classes, class methods, OOP.

If you can think of something memorable you did in a class or for fun that taught you something about Java classes I'd love suggestions.

I'm finding all the examples dry and boring. "The student class is a subclass of the people class"

Any suggestions?

heathborders ,
@heathborders@hachyderm.io avatar

@futurebird I always thought that non-static inner classes were interesting:
class A { class B {} }
class C {
public static void main(String[] args) {
A a = new A();
B b1 = a.new B();
B b2 = a.new B();
}
}

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • test
  • worldmews
  • mews
  • All magazines