java 课后答案05review.docVIP

  • 4
  • 0
  • 约3.79千字
  • 约 4页
  • 2018-01-10 发布于河南
  • 举报
java 课后答案05review

Chapter 5 Methods 1. At least three benefits: (1) Reuse code; (2) Reduce complexity; (3) Easy to maintain. See the Sections 5.2 and 5.3 on how to declare and invoke methods. What is the subtle difference between “defining a method” and “declaring a variable”? A declaration usually involves allocating memory to store a variable, but a definition doesn’t. 2. void Yes. return (num1 num2) ? num1 : num2; 4. True: a call to a method with a void return type is always a statement itself. False: a call to a value-returning method is always a component of an expression. 5. A syntax err

您可能关注的文档

文档评论(0)

1亿VIP精品文档

相关文档