Introduction
Here is the source code for Main.java
Source
//package com.java2s;
public class Main {
static int getDistance(int rssi) {
int irssi = Math.abs(rssi);
double power = (irssi - 70.0) / (10 * 2.0);
power = Math.pow(10d, power);
power = power * 100;
return (int) power;
}
}