question: public static String cutSuffix ( String string , String suffix ) { if ( string . endsWith ( suffix ) ) { string = string . substring ( 0 , string . length ( ) - suffix . length ( ) ) ; } return string ; }
target:  Cuts sufix if exists.