본문 바로가기

C++197

[Programmers] (2018 KAKAO BLIND RECRUITMENT) Lv 2. [1차] 뉴스 클러스터링 https://school.programmers.co.kr/learn/courses/30/lessons/17677 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include #define MULTIPLE 65536 using namespace std; int Min(int A, int B) { return A B ? A : B; } int Check_State(char C) { if ('A' 2023. 6. 16.
[Programmers] (스택/큐) Lv 2. 프로세스 https://school.programmers.co.kr/learn/courses/30/lessons/42587 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include #include using namespace std; int solution(vector priorities, int location) { int answer = 0; deque q; for (int i = 0; i < priorities.size(); ++i) q.emplace_back(make_pair(i, priorities[i])); auto.. 2023. 6. 16.
[Programmers] Lv 2. 할인 행사 https://school.programmers.co.kr/learn/courses/30/lessons/131127 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include using namespace std; int solution(vector want, vector number, vector discount) { int answer = 0; unordered_map m; for (int i = 0; i < number.size(); ++i) m[want[i]] = number[i]; unordered_map bet.. 2023. 6. 16.
[Programmers] (스택/큐) Lv 2. 기능개발 https://school.programmers.co.kr/learn/courses/30/lessons/42586 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include using namespace std; vector solution(vector progresses, vector speeds) { vector answer; int day = 0; for (auto iter = progresses.begin(); iter != progresses.end(); ++iter) { int speed = speeds[ite.. 2023. 6. 16.
[Programmers] (2019 카카오 개발자 겨울 인턴십) Lv 2. 튜플 https://school.programmers.co.kr/learn/courses/30/lessons/64065 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include #include #include #include #include using namespace std; bool cmp(const pair& a, const pair& b) { if (a.second == b.second) return a.first b.second; } vector solution(.. 2023. 6. 16.
[DirectX12 - Camera & Lighting] Chapter 03. Lighting GitHub : https://github.com/developeSHG/DirectX12-Camera_Lighting/commits/03.Lighting GitHub - developeSHG/DirectX12-Camera_Lighting: DirectX12 - Camera & Lighting DirectX12 - Camera & Lighting. Contribute to developeSHG/DirectX12-Camera_Lighting development by creating an account on GitHub. github.com 물체마다 자신의 RGB 값이 있는데, 거기다 각각 곱해지는 성분자체를 구하는 것이 Lighting의 개념. 예시) R(1) * 0.5 G(0) * 0.5 B(0) * 0.. 2023. 6. 15.
[DirectX12 - Camera & Lighting] Chapter 02. Resources GitHub : https://github.com/developeSHG/DirectX12-Camera_Lighting/commits/02.Resources GitHub - developeSHG/DirectX12-Camera_Lighting: DirectX12 - Camera & Lighting DirectX12 - Camera & Lighting. Contribute to developeSHG/DirectX12-Camera_Lighting development by creating an account on GitHub. github.com 2023. 6. 15.
[DirectX12 - Camera & Lighting] Chapter 01. Camera GitHub : https://github.com/developeSHG/DirectX12-Camera_Lighting/commits/01.Camera GitHub - developeSHG/DirectX12-Camera_Lighting: DirectX12 - Camera & Lighting DirectX12 - Camera & Lighting. Contribute to developeSHG/DirectX12-Camera_Lighting development by creating an account on GitHub. github.com 2023. 6. 15.
[Programmers] (해시) Lv 2. 의상 https://school.programmers.co.kr/learn/courses/30/lessons/42578 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include #include using namespace std; int solution(vector clothes) { int answer = 1; unordered_map m; for_each(clothes.begin(), clothes.end(), [&](const auto& v) { ++m[v[1]]; }); for (auto& e : m) answer .. 2023. 6. 15.
[Programmers] (2018 KAKAO BLIND RECRUITMENT) Lv 2. [1차] 캐시 https://school.programmers.co.kr/learn/courses/30/lessons/17680 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include #include #include using namespace std; #define CACHE_HIT 1 #define CACHE_MISS 5; class LRU { public: explicit LRU(int n) { LRUMaxSize = n; LRUTime = 0; } void refer(string n) { // 캐시 내에 없을 경우 if (.. 2023. 6. 15.