[백준] JAVA/입출력과 사칙연산
[백준] JAVA 2588: 곱셈
코딩하는곰곰
2022. 2. 4. 20:20
https://www.acmicpc.net/problem/2588
Solution:
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a, b, c;
a = sc.nextInt();
b = sc.nextInt();
int one, two, three;
one = b/100;
two = b/10%10;
three = b%10;
System.out.println(a*three);
System.out.println(a*two);
System.out.println(a*one);
System.out.println(a*b);
}
}