MainClass.java Source code

Java tutorial

Introduction

Here is the source code for MainClass.java

Source

public class MainClass {

    public static void main(String[] a) {
        double x = 27.5, y = 33.75;
        String outString = String.format("x = %15.2f y = %14.3g", x, y);

        System.out.println(outString);
    }

}