Calculating BMI(Body Mass Index)

 

import java.util.*;
public class BMI{
public static void main(String args[])
{
Scanner sc = new Scanner(System.in);
System.out.println("Enter weight in Kgs");
int weight = sc.nextInt();
System.out.println("Enter height in inches");
int height = sc.nextInt();

// double BMI = weight/(height*0.0254*height*0.0254);
double BMI = weight/(Math.pow(height*0.0254,2));
System.out.println("Body Mass Index for given parameters is "+BMI);
}
}

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...