What are purposes of methods? What are three items that must be included in the method header? What does "void" mean for a return data type?

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter8: Arrays
Section: Chapter Questions
Problem 20RQ
icon
Related questions
Question
Concepts of Methods
1. What are purposes of methods?
2. What are three items that must be included in the method header?
3. What does "void" mean for a return data type?
4. What is a variable scope for a parameter?
5. Create a method that will take client's integer array and sort the
elements of the client's array in an ascending order.
a. Write a method header in Java. (Note that Java passes an array
by reference)
b. Write a method body. (Suggestion: use a bubble sort method)
c. How do you call the method if client has an array named
myNum?
Transcribed Image Text:Concepts of Methods 1. What are purposes of methods? 2. What are three items that must be included in the method header? 3. What does "void" mean for a return data type? 4. What is a variable scope for a parameter? 5. Create a method that will take client's integer array and sort the elements of the client's array in an ascending order. a. Write a method header in Java. (Note that Java passes an array by reference) b. Write a method body. (Suggestion: use a bubble sort method) c. How do you call the method if client has an array named myNum?
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Function Calling
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT