c++86 [정올] #9001 출력 - 연습문제1(c++) https://jungol.co.kr/problem/9001?cursor=eyJwcm9ibGVtc2V0IjoiMiIsImZpZWxkIjowLCJpZHgiOjB9 JUNGOL code_blocks 코드 보기 jungol.co.kr 답 #include using namespace std; int main(){ ios_base::sync_with_stdio(0); cin.tie(0); cout 2024. 2. 10. [프로그래머스] 왼쪽 오른쪽(c++) https://school.programmers.co.kr/learn/courses/30/lessons/181890 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 답 #include #include using namespace std; vector solution(vector str_list) { vector answer; for(int i=0;i 2024. 2. 2. [프로그래머스] 배열 만들기 5(c++) https://school.programmers.co.kr/learn/courses/30/lessons/181912 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 답 #include #include using namespace std; vector solution(vector intStrs, int k, int s, int l) { vector answer; int temp; for(int i=0;ik){ answer.push_back(temp); } } return answer; } 1. 변수 'answer': 조건의 맞는 정수들을 저장하기 위해 사용된.. 2024. 2. 1. [프로그래머스] 커피 심부름(c++) https://school.programmers.co.kr/learn/courses/30/lessons/181837 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 답 #include #include using namespace std; int check(string order){ if(order=="americano"||order=="iceamericano"||order=="americanoice"||order=="hotamericano"||order=="americanohot"||order=="anything"){ return 4500; } else{ .. 2024. 2. 1. [프로그래머스] 0 떼기(c++) https://school.programmers.co.kr/learn/courses/30/lessons/181847 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 답 #include #include using namespace std; string solution(string n_str) { string answer = ""; bool a=true; for(int i=0;i 2024. 1. 31. [프로그래머스] 정사각형으로 만들기(c++) https://school.programmers.co.kr/learn/courses/30/lessons/181830 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 답 #include #include using namespace std; vector solution(vector arr) { int check; if(arr.size()>arr[0].size()){ check=arr.size()-arr[0].size(); for(int i=0;i 2024. 1. 31. 이전 1 2 3 4 5 6 7 ··· 15 다음