import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner s = new Scanner(System.in); String str = s.next(); s.close(); String sub = str.substring(str.length()-2); String ai; if(sub.equalsIgnoreCase("AI")){ ai = str.substring(0, str.length()-2)+"AI"; }else{ ai = str+"-AI"; } System.out.println(ai); } }