Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import java.text.DecimalFormat;

public class Main {
    public static String getFormattedLocationString(double[] coordinates, String address) {
        DecimalFormat df = new DecimalFormat();
        return address + " " + "Lat: " + String.format("%.4f", coordinates[0] / 1E6) + " Lon: "
                + String.format("%.4f", coordinates[1] / 1E6);
    }
}