/**
* File name: UtilsString.java
* Version: 1.0
* Date: @date 13:17:19
* Author: Sawan J. Kapai Harpalani
* Copyright: Copyright 200X Sawan J. Kapai Harpalani
*
* This file is part of Math Attack.
*
* Math Attack is free software: you can redistribute it
* and/or modify it under the terms of the GNU General
* Public License as published by the Free Software
* Foundation, either version 3 of the License,
* or (at your option) any later version.
*
* Math Attack is distributed in the hope that it will
* be useful, but WITHOUT ANY WARRANTY; without even
* the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General
* Public License along with Math Attack. If not, see
* http://www.gnu.org/licenses/.
*/
package com.sawan.mathattack.utils;
// TODO: Auto-generated Javadoc
/**
* The Class UtilsString.
*/
public class UtilsString {
/**
* Remove last chracter of a string.
*
* @param s the s
* @return the string
*/
public static String removeLastChar(String s) {
if (s == null || s.length() == 0) {
return s;
}
return s.substring(0, s.length() - 1);
}
}