|
-
Jul 4th, 2003, 07:22 PM
#1
Thread Starter
New Member
class
i m new in java and would like to ask a silly question. is 1 program means 1 class?? or 1 program can have many class?? for example:
public class first
public static void main (string arg[]){
code.....
public static void register (string arg[])
{ code......}
public static void sales (string arg[])
{ code....}
public static void play (string arg[])
{ code....}
}
please advice
thank you
-
Jul 4th, 2003, 10:39 PM
#2
Frenzied Member
Read up on OOP (Object Oriented Programming) and Inheritance. It will give you a better understanding of what classes are, and how they work within programs.
Being educated does not make you intelligent.
Need a weekend getaway??? Come Visit
-
Jul 5th, 2003, 06:45 PM
#3
Dazed Member
One program can have one class or many classes. That all depends on the program. Java does allow you to declare multiple classes in one file with only one class(the class the file is named after) being public.
Last edited by Dilenger4; Jul 5th, 2003 at 06:50 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|