본문 바로가기

전체 글

(2344)
(C++) - 백준(BOJ) 4696 : St. lves https://www.acmicpc.net/problem/4696 4696번: St. Ives Input consists of multiple data sets. Each data set consists of a line with a single floating point number number representing the numbers of wives, sacks per wife, cats per sack, and kittens per cat that Robert encountered that year. End of input is indic www.acmicpc.net 간단 구현문제였습니다. 📕 풀이방법 📔 입력 및 초기화 공식을 적용할 a를 선언 후 입력받습니다. 📔 정답출력 공식을 적용한 결과..
(C++) - 백준(BOJ) 3512 : Flat https://www.acmicpc.net/problem/3512 3512번: Flat You are one of the developers of software for a real estate agency. One of the functions you are to implement is calculating different kinds of statistics for flats the agency is selling. Each flat consists of different types of rooms: bedroom, bathroom, k www.acmicpc.net 출력을 신경써야하는 구현 문제였습니다. 📕 풀이방법 📔 입력 및 초기화 방 종류별 크기의 합을 저장할 map 변수 sizePerType,..
(C++) - 백준(BOJ) 2712 : 미국 스타일 https://www.acmicpc.net/problem/2712 2712번: 미국 스타일 첫째 줄에 테스트 케이스의 개수 T(1 t; while(t--){ cin >> weight >> unit; printf("%.4f", getConvertedWeight()); cout
(C++) - 백준(BOJ) 24724번 : 현대모비스와 함께하는 부품 관리 https://www.acmicpc.net/problem/24724 24724번: 현대모비스와 함께하는 부품 관리 첫 번째 줄에 부품 관리 횟수를 나타내는 양의 정수 $T$가 주어진다. ($1 \le T \le 10$) 각 부품 관리에 대한 입력은 다음과 같이 주어진다. 첫 번째 줄에는 부품의 개수를 나타내는 양의 정수 $N$이 www.acmicpc.net 간단 출력문제였습니다. 📕 풀이방법 📔 입력 및 초기화 test case t, 부품 set 개수 n, 크기와 무게 제한 l1, l2, 부품 크기 무게 정보 a, b를 선언 후 적절히 입력받습니다. 📔 정답출력 형식에 맞게 출력해줍니다. 📕 Code #include using namespace std; int t, n, l1, l2, a, b; int ..
(C++) - 백준(BOJ) 10698 번 : Ahmed Aly https://www.acmicpc.net/problem/10698 10698번: Ahmed Aly Your program will be tested on one or more test cases. The first line of the input will be a single integer T, the number of test cases (1 ≤ T ≤ 100). Followed by T lines, each test case is a single line containing an equation in the following format www.acmicpc.net 간단 구현 문제였습니다. 📕 풀이방법 📔 입력 및 초기화 test case 수 t, a op b = res 형태의 수식을 받을 수 있도..
(C++) - 백준(BOJ) 9724 번 : Perfect Cube https://www.acmicpc.net/problem/9724 9724번: Perfect Cube A perfect cube is an integer whose cube root is also an integer. For example 1, 8, 27, 64, 125, etc. are examples of perfect cubes but 9, 25 and 113 are not. Given two positive integers A and B, your task is to calculate the number of perfect cubes in the www.acmicpc.net 전수조사 문제였습니다. 📕 풀이방법 📔 입력 및 초기화 test case t, 범위 (a, b), map m, 정답을 출력할..
(C++) - 백준(BOJ) 10395 번 : Automated Checking Machine https://www.acmicpc.net/problem/10395 10395번: Automated Checking Machine The first line contains five integers Xi (0 ≤ Xi ≤ 1 for i = 1, 2, . . . , 5), representing the connection points of the first connector in the pair. The second line contains five integers Yi (0 ≤ Yi ≤ 1 for i = 1, 2, . . . , 5), representing the c www.acmicpc.net 간단한 전수조사 문제였습니다. 📕 풀이방법 📔 입력 및 초기화 5개의 정수를 입력받을 배열 a와 정답을 출력..
(Ubuntu Wsl 2) - docker명령어 써보기 🍳머리말 docker명령어를 사용하는 예제입니다. 📕 Prerequisite 📔 docker 📔 docker desktop 📕설명 📔 오류 local에서 docker를 설치했지만 docker명령어를 wsl 2 terminal 내에서 치면 다음 error가 나옵니다. 이는 wsl 2에 연동가능한 docker engine을 선택하지 않았기 때문입니다. 📔 해결 docker desktop를 local에서 실행시켜서 다음과 같이 설정해줍니다. 설정 중 화면 📔 확인 wsl terminal내에서 다시 docker명령어를 치면 정상 동작합니다. *더 나은 내용을 위한 지적, 조언은 언제나 환영합니다.