From c04fcccb76b674e2ebb55cea3d687941f92c113c Mon Sep 17 00:00:00 2001 From: TechNing39 Date: Wed, 5 Nov 2025 19:30:18 +0900 Subject: [PATCH 1/2] =?UTF-8?q?251105=20K=EB=B2=88=EC=A7=B8=20=ED=81=B0=20?= =?UTF-8?q?=EC=88=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...62\210\354\247\270 \355\201\260 \354\210\230.py" | 13 ------------- section2/tempCodeRunnerFile.py | 13 +------------ 2 files changed, 1 insertion(+), 25 deletions(-) delete mode 100644 "section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" diff --git "a/section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" "b/section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" deleted file mode 100644 index bc86a6b..0000000 --- "a/section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" +++ /dev/null @@ -1,13 +0,0 @@ -N,K=map(int,input().split()) -cards=list(map(int,input().split())) -result=set() - -for i in range(N): - for j in range(i+1,N): - for m in range(j+1,N): - result.add(cards[i]+cards[j]+cards[m]) - -result=list(result) -result.sort(reverse=True) - -print(result[K-1]) \ No newline at end of file diff --git a/section2/tempCodeRunnerFile.py b/section2/tempCodeRunnerFile.py index 998fa51..f240844 100644 --- a/section2/tempCodeRunnerFile.py +++ b/section2/tempCodeRunnerFile.py @@ -1,12 +1 @@ -T=int(input()) - -for i in range(1,T+1): - N,s,e,k=map(int,input().split()) - - numbers=list(map(int,input().split())) - - list=numbers[s-1:e] - list.sort() - result=list[k-1] - - print(f"#{i} {result}") \ No newline at end of file + print(index) \ No newline at end of file From d994a0490943e1e2a17d6a39d89de4cdb840bd81 Mon Sep 17 00:00:00 2001 From: TechNing39 Date: Wed, 5 Nov 2025 19:31:01 +0900 Subject: [PATCH 2/2] =?UTF-8?q?251105=20K=EB=B2=88=EC=A7=B8=20=ED=81=B0=20?= =?UTF-8?q?=EC=88=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...62\210\354\247\270 \355\201\260 \354\210\230.py" | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 "section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" diff --git "a/section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" "b/section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" new file mode 100644 index 0000000..bc86a6b --- /dev/null +++ "b/section2/K\353\262\210\354\247\270 \355\201\260 \354\210\230.py" @@ -0,0 +1,13 @@ +N,K=map(int,input().split()) +cards=list(map(int,input().split())) +result=set() + +for i in range(N): + for j in range(i+1,N): + for m in range(j+1,N): + result.add(cards[i]+cards[j]+cards[m]) + +result=list(result) +result.sort(reverse=True) + +print(result[K-1]) \ No newline at end of file