首页 > 代码库 > Java标准输入

Java标准输入

Java:		import java.util.*;		public class Main{			public static void main(String args[]){				Scanner cin = new Scanner(System.in);				int a, b;				while (cin.hasNext()){					a = cin.nextInt(); b = cin.nextInt();					System.out.println(a + b);				}			}		}