Jump to content

Main method in each class..~

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
1 reply to this topic

#1
Guest_R3.RyozKidz_*

Guest_R3.RyozKidz_*
  • Guests
I have 2 classes by now..~ A and B..~

I have created class A for certain functionality purpose . And at class B , i have created an object of class A .

If there any chances that for me to create another of main method in class A while i still have the object of the class A in class B ??

#2
Sinipull

Sinipull

    Programming Expert

  • Members
  • PipPipPipPipPipPip
  • 386 posts
Why would you want to do that? Main function is a place where program starts to run. If you need two different starting locations, then create two different starting classes, but don't use one in the other.

Make three classes: A, B and C.
So, C contains the logic and A, B contains different starting points, or main methods.