• Post Reply Bookmark Topic Watch Topic
  • New Topic

java beginner  RSS feed

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A public static method named detTotal() is located in classA. To call the method from within classB, use the statement ____________.
A) detTotal(classB);
B) detTotal().classA;
C) classB.detTotal();
D) classB(detTotal());
E) classA.detTotal();
F) You cannot call detTotal() from within classB.
 
author & internet detective
Marshal
Posts: 37518
554
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Wayne. Welcome to CodeRanch!

This looks like a homework assignment. What do you think the answer is and why? What specifically do you want to know?
 
Bartender
Posts: 572
9
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The instructor (or book author) who assigned this problem should be chastised for not beginning class names with a capital letter.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!