write code in java write a static method that will take in a lone integer parameter. this function will return 1 if the number provided is odd, 0 if it is even. write a line of code that will call the function you just wrote above, passing it the contents of a variable called value and have it assigned the value returned by the function another variable called answer(both variables are already declared.)

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter8: Advanced Method Concepts
Section: Chapter Questions
Problem 7E
icon
Related questions
Question
  • write code in java
  • write a static method that will take in a lone integer parameter. this function will return 1 if the number provided is odd, 0 if it is even.
  • write a line of code that will call the function you just wrote above, passing it the contents of a variable called value and have it assigned the value returned by the function another variable called answer(both variables are already declared.)
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,