Here you can find the source of getScoreDifferenceString(int newNumber, int oldNumber)
public static String getScoreDifferenceString(int newNumber, int oldNumber)
//package com.java2s; //License from project: Apache License import java.text.DecimalFormat; public class Main { public static String getScoreDifferenceString(int newNumber, int oldNumber) { DecimalFormat format = new DecimalFormat("+#;-#"); return format.format(newNumber - oldNumber); }//from w ww .j a v a 2 s .com }