MethodSignature - { int a; double b; test(a, b);...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
//Program: Method Signature //Shows syntax error //Signature refers to the method name and parameter list //not the return type. / import java.util.*; i public class MethodSignature { static Scanner console = new Scanner(; public static void main (String[] args)
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: { int a; double b; test(a, b); System.out.println("a = " + a + ", b = ", b + ", test(a, b) = ", test(a, b)); } public static void test(int x, double y) { x = x + y; y = 2 * y; } public static double test(int x, double y) { y = 2 * x; return y; } }...
View Full Document

This note was uploaded on 06/17/2011 for the course COMP 2301 taught by Professor Staff during the Spring '10 term at Kennesaw.

Ask a homework question - tutors are online