![[백준 알고리즘] 2577번 숫자의 개수(Python 3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FB31c8%2FbtqBS6dDDlu%2FAAAAAAAAAAAAAAAAAAAAAOuVPiJAMtX6YYMuTBKyu9dwN42OxmLv_HkuP6TUw8XS%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DmWfxoScmws1SVjJ5ySCj3o1lmfg%253D)
a = int(input()) b = int(input()) c = int(input()) list = [0 for _ in range(10)] mul = str(a * b * c) for i in range(len(mul)): list[int(mul[i])] += 1 for i in list: print(i) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputSt..
![[백준 알고리즘] 2562번 최댓값(Python 3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FbcWuLb%2FbtqBWrHpUNB%2FAAAAAAAAAAAAAAAAAAAAACYsul4qGFUz_yEjx4sJ3B-6-MvWNVdBT5cZGZDImSZi%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DQhVfpe5GkFtAm5sqHtUyQd%252FmdbI%253D)
a = list() for i in range(9): a.append(int(input())) print(max(a), a.index(max(a))+1) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int max = 0; int max_idx = 0; for(int i=0; imax){ max = num; max_..
![[백준 알고리즘] 10818번 최소, 최대(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2Fb8qtRR%2FbtqBUUjhoJh%2FAAAAAAAAAAAAAAAAAAAAABYZOQpYZhaA9_dbLOg6mZ3NwBPLPGuSZAqEiUdIEvJe%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3D3nNQwuP%252FULbg%252BdSPyX6vsxDirPE%253D)
n = int(input()) a = list(map(int,input().split())) min, max = a[0], a[0] for i in range(n): if a[i] max: max = a[i] print(min, max) 출처: https://hwiyong.tistory.com/217 Case = int(input()) num_list = list(map(int, input().split())) print('{} {}'.format(min(num_list), max(num_list))) 문자열 대괄호 자리에 format 뒤의 괄호안에 있는 값을 하나씩 넣어 출력한다. import java.io.BufferedReader; import ja..
![[백준 알고리즘] 1110번 더하기 사이클(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FIMxcG%2FbtqBS7cAClb%2FAAAAAAAAAAAAAAAAAAAAAIqbGxQAipBIsKzcT7TQ1OrUqYvgzXuF5--w3oeElxLp%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DOyM5QlVdEuK2Nrf393mhh1byb7k%253D)
n = nn = int(input()) cycle = 0 while True: res = (n // 10) + (n % 10) cycle += 1 n = int(str(n % 10) + str(res % 10)) if nn == n: break print(cycle) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); i..
![[백준 알고리즘] 10951번 A+B - 4(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FcfgJmi%2FbtqBRw4LMrU%2FAAAAAAAAAAAAAAAAAAAAAGPlewh7EJwPbHbQJpUhQr72U6Catk8-Dazv8CWHjD_j%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DQHexjX0zG5gRYIbL285nNAZ9HMI%253D)
import sys try: while True: line = sys.stdin.readline() a, b = line.split() print(int(a) + int(b)) except: exit() 입력 개수를 모르기 때문에 try except를 사용하였다. import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new ..
![[백준 알고리즘] 10952번 A+B - 5(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FPJKdD%2FbtqBUA6fWjP%2FAAAAAAAAAAAAAAAAAAAAACXeEXSVjee1QXFG642cFFefOs9AibjfJRY-XsayjBhL%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DmIlLmnJP4EyY%252F%252FQ8zFRoZ7c7SI0%253D)
import sys while(1): line = sys.stdin.readline() a, b = line.split() if a == '0' and b == '0': break print(int(a)+int(b)) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); while(true){ String[] line = ..
![[백준 알고리즘] 11022번 A+B - 8(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FIK5e7%2FbtqBWrUMpGk%2FAAAAAAAAAAAAAAAAAAAAAGEbT0BVgUpIFyNLEVk-muj-EaI--jcZLU17KJN9yETE%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3D3ErX3b6pW1pmAAzQtJ%252FbGiUbfVs%253D)
import sys n = int(sys.stdin.readline()) for i in range(1, n+1): line = sys.stdin.readline() a, b = line.split() print("Case #%d: %d + %d = %d" %(i, int(a), int(b), int(a)+int(b))) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class b_11022 { public static void main(String[] args) throws IOException { Buffere..
![[백준 알고리즘] 11021번 A+B - 7(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FlDpGb%2FbtqBS6EA5hx%2FAAAAAAAAAAAAAAAAAAAAACBABwbIFf3nzXdjRdLhrHAlt-eyepBXsHobxUxqJY8s%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DM0a%252Fyb%252FI1IMISju%252Fwd5E%252BC2xV3o%253D)
import sys n = int(sys.stdin.readline()) for i in range(1, n+1): line = sys.stdin.readline() a, b = line.split() print("Case #%d: %d" %(i,int(a)+int(b))) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class b_11021 { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedRe..
![[백준 알고리즘] 1552번 빠른 A+B(Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FcWbX26%2FbtqBS6YNfuo%2FAAAAAAAAAAAAAAAAAAAAAMYShUXrF8IALny-y47cF6znxPO44hWymLaZiNBTabPH%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3DLmYHTW20BPnWeyNaCIzA9l1XroE%253D)
import sys n = sys.stdin.readline() n= int(n) for i in range(n): line= sys.stdin.readline() a,b = line.split() print(int(a)+int(b)) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class b_15552 { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamRe..
![[백준 알고리즘] 10950번 A+B-3 (Python3, Java)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdna%2FlcP4f%2FbtqBWr8iRay%2FAAAAAAAAAAAAAAAAAAAAAOKIMqoiyCOCzXaaLRqTB0ffgScy4Zq8tJzEKczjm48k%2Fimg.png%3Fcredential%3DyqXZFxpELC7KVnFOS48ylbz2pIh7yKj8%26expires%3D1753973999%26allow_ip%3D%26allow_referer%3D%26signature%3D%252BM8Nq3tSaPXfuKFAyN1FaEH%252FX74%253D)
n = int(input()) for i in range(n): a,b = input().split() print(int(a)+int(b)) import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class b_10950 { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int T = Integer.parseInt(br.readLin..