[BOJ] 2588번 곱셈
백준#2588 곱셈
https://www.acmicpc.net/problem/2588
코드 - Python
a= int(input())
b= int(input())
fst = a*(b%10)
snd = a*((b//10)%10)
lst = a*(b//100)
print(fst,snd,lst,a*b,sep="\n")
코드 - Java
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a,b,fst,snd,lst;
a = sc.nextInt();
b = sc.nextInt();
fst = a*(b%10);
snd = a*((b/10)%10);
lst = a*(b/100);
System.out.println(fst+"\n"+snd+"\n"+lst+"\n"+a*b);
}
}
Author And Source
이 문제에 관하여([BOJ] 2588번 곱셈), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://velog.io/@_koiil/BOJ-2588번-곱셈저자 귀속: 원작자 정보가 원작자 URL에 포함되어 있으며 저작권은 원작자 소유입니다.
우수한 개발자 콘텐츠 발견에 전념 (Collection and Share based on the CC Protocol.)