Adding two numbers using a non-static parametric method

 

import java.util.*;
public class Addition {
public int add(int x, int y) {
int result = x + y;
return result;
}

public static void main(String args[]) {
Scanner sc = new Scanner(System.in);
System.out.println("Enter first number");
int a = sc.nextInt();
System.out.println("Enter second number");
int b = sc.nextInt();

Addition add = new Addition();

int result = add.add(a, b);
System.out.println("The sum of two given numbers is = " + result);

}
}

Google Script for Data Entry Form in Google Spreadsheet

// function to validate the entry made by user in user form function validateEntry (){ // declare a variable and referernece of active goog...