📌URL https://school.programmers.co.kr/learn/courses/30/lessons/12917 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 import java.util.Arrays; class Solution { public String solution(String s) { int[] list = new int[s.length()]; StringBuilder answer = new StringBuilder(); for(int i = 0; i < s.length(); i++) { list[i] = ((int)s.cha..
📌URL https://school.programmers.co.kr/learn/courses/30/lessons/82612 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 class Solution { public long solution(int price, int money, int count) { long answer = 0; for(int i = 1; i 0 ? answer - money : 0; } } for문을 count만큼 돌려 answer에 price * i를 더해주었다. 그리고 answer - money의 값이 0보다 크다면 부족한 값..
📌URL https://school.programmers.co.kr/learn/courses/30/lessons/70128 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 class Solution { public int solution(int[] a, int[] b) { int answer = 0; for(int i = 0; i < a.length; i++) { answer += a[i] * b[i]; } return answer; } } 문제 설명에 a와 b의 내적이라 되어있어 어려운 문제인가 했는데 for문을 돌려 배열 a와 배열 b의 요소를 ..
📌URL https://school.programmers.co.kr/learn/courses/30/lessons/86051 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 import java.util.ArrayList; class Solution { public int solution(int[] numbers) { int answer = 0; ArrayList list = new ArrayList(); for(int i =0; i < 10; i++) { list.add(i); } for(int i = 0; i
📌URL https://school.programmers.co.kr/learn/courses/30/lessons/12918 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 class Solution { public boolean solution(String s) { for(int i = 0; i < s.length(); i++) { if(!('0'
📌URL https://school.programmers.co.kr/learn/courses/30/lessons/12969 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 import java.util.Scanner; class Solution { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); for(int i = 0; i < b; i++) { for(int j = 0; j < a..
📌URL https://school.programmers.co.kr/learn/courses/30/lessons/59403 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 🔎풀이 SELECT ANIMAL_ID,NAME FROM ANIMAL_INS ORDER BY ANIMAL_ID ASC;