一、题目描述
二、代码
import java.math.BigInteger;
import java.util.Scanner;
import java.util.StringTokenizer;
public class Main {
public static void main(String[] args) {
@SuppressWarnings("resource")
Scanner in = new Scanner(System.in);
int n = in.nextInt();
String command;
BigInteger res = null;
boolean isStart = false;
int ope = 0;
int PN = 10;
in.nextLine();
for(int i = 0; i < n; i++){
StringTokenizer stringTokenizer = new StringTokenizer(in.nextLine());
command = stringTokenizer.nextToken();
if(command.equals("CHANGE")){
String str = stringTokenizer.nextToken();
PN = Integer.parseInt(str);
}
else if(command.equals("EQUAL"