/*
public class Main {
}
자동완성은 컨트롤 스페이스
메소드==함수
컴파일= 컨트롤 에프 11
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
System.out.println("hello"+" my");
Scanner sc =new Scanner(System.in);
int a;
a=sc.nextInt();
System.out.println("입력받은 숫자는 "+a+" 입니다");
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int a,b;
a=sc.nextInt();
b=sc.nextInt();
System.out.printf("%d",a%b);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int a,b;
a= sc.nextInt();
b= sc.nextInt();
System.out.printf("%d",a>b?a:b);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int a;
a=sc.nextInt();
System.out.printf("%d %d",a/60,a%60);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc=new Scanner(System.in);
int a;
a= sc.nextInt();
System.out.printf("%d %d %d",a,a,a);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String v = sc.nextLine();
char a = v.charAt(0);
char b = v.charAt(2);
System.out.printf("%c %c",b,a);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a,b;
a= sc.nextInt();
b= sc.nextInt();
System.out.printf("%d %d",a,b);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int a,b;
a=sc.nextInt();
b=sc.nextInt();
System.out.printf("%d",a/b);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int a,b;
a=sc.nextInt();
b=sc.nextInt();
System.out.printf("%d+%d=%d\n%d-%d=%d\n%d*%d=%d\n%d/%d=%d",a,b,a+b,a,b,a-b,a,b,a*b,a,b,a/b);
}
}
*/
/*
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
float a,b,c;
int d;
a=sc.nextFloat();
b=sc.nextFloat();
c=sc.nextFloat();
System.out.printf("%.0f %.1f",a+b+c,(a+b+c)/3);
}
}
*/
import java.util.*;
public class Main{
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int a,b;
a=sc.nextInt();
b=sc.nextInt();
float f=a;
float d=b;
System.out.printf("%d %d %d %d %d %.2f",a+b,a-b,a*b,a/b,a%b,f/d);
}
}
메소드 == 함수
자동완성 ctrl + space
컴파일 ctrl + F11
문자열끼리는 +로 연결 가능하다
이클립스 + jdk 설치하기
import java.util.*; //c에서 #include <stdio.h>와 같은것
public class Main{
public static void main(String[] args) {
//자료형
//정수 int long
//실수 float double
//문자 char
//문자열 String
//불린 boolean - true or false
// boolean flag = true;
// System.out.println(!flag);
//입력
Scanner sc = new Scanner(System.in); // 스캐너 객체 생성
//int a;
//a = sc.nextInt();
//System.out.println("입력하신 숫자는 "+a+"입니다.");
// long b = sc.nextLong();
//float c = sc.nextFloat();
//String str = sc.next(); //한 단어 (공백x)
//String str = sc.nextLine(); //공백까지 전부 받기
//System.out.println(str);
//연산자 + - * / %
//비교 > < >= <= == !=
//논리 ! && ||
//삼항 (조건식)?조건식이참일때의값:거짓일때의값 -> 둘 중 큰수, 둘 중 작은 수
// a>b?a:b
//int a=10, b=5;
//System.out.println(a==b);
//float a = sc.nextFloat();
//System.out.println(a);
//System.out.printf("%.2f",a);
//if else switch case for while do-while
//while(true){ }
System.out.println("안녕\n하세요");
String str = sc.next();
char a = str.charAt(0);
char b = str.charAt(2);
}
}