0
Is someone available to teach me the classes and objects?
6 Answers
+ 1
Classes are like blueprints. They contain the information needed to make an object. Here is a class:
class player
{
public string name { get; set; }
}
Let's use it to make an object:
player hero = new player();
hero.name = "Rikimaru";
"hero" is the object and "name" is the object's property.
edit: sorry this is C#.
+ 1
The technique can be used in all sorts of situations. Video games spring to mind. The player class can be re-used to make all the characters in a game. Obviously this is basic. A real player class would contain tons of properties. And that is why OOP is so important in big projects.
+ 1
I wouldn't worry too much at the moment, it confused me as well. But once my knowledge and experience grew, it started to make sense. Keep on coding!
+ 1
Student.
0
uses for??
0
r u student or teacher