Java Help!

  HasH 15:02 17 Feb 03
Locked

Does anyone know the differances between instance variables and methods? Comparisons would be helpful too.

Thanx

  Elrond 15:26 17 Feb 03

Instance Variable = A variable that describes an attribute of an instance of a class instead of the class itself.

Method = A group of statements in a class that defines how the class's objects will behave.

  QuickHare 17:05 17 Feb 03

Instance Variable - A particular being of a class. A String class is a group of objects which are String. "Hello World" is a particular String. An instance variable is the same sort of thing.

Method - Something can be applied to an instance variable. myString.toUpper() is a method as it converts the string in myString to uppercase.



Different methods and variables appear in different types of objects.

This thread is now locked and can not be replied to.

What is Amazon Go and will it come to the UK? The store without checkouts or queues

1995-2015: How technology has changed the world in 20 years

Hands-on with the Star Wars fighting drones you can fly yourself

iPhone 9 and beyond: 32 amazing future smartphone developments - graphene, supercapacitor…