Java中的方法.pptVIP

  • 24
  • 0
  • 约2.33万字
  • 约 43页
  • 2018-05-21 发布于江苏
  • 举报
第六章 – Methods 方法 6.1 Introduction 模块化思想 简化程序设计 分模块进行设计,对于大程序系统设计有利 6.2 Program Modules in Java Java 中的模块 Methods Classes Java API provides several modules Programmers can also create modules e.g., programmer-defined methods Methods Invoked by a method call Returns a result to calling method (caller) Similar to a boss (caller) asking a worker (called method) to complete a task 6.3 Math-Class 方法 Class java.lang.Math Provides common mathematical calculations Calculate the square root of 900.0: Math.sqrt( 900.0 ) Method sqrt belongs to class Math Dot (.) allows access to method sqrt T

文档评论(0)

1亿VIP精品文档

相关文档