From 9cf53c40f86dcdfd98eb33c0c30a6bbcbd94e7bb Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Mon, 30 Jan 2023 12:31:46 +0900 Subject: [PATCH 1/9] =?UTF-8?q?Create=20=ED=8F=B0=EC=BC=93=EB=AA=AC=20kyuh?= =?UTF-8?q?yun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../\355\217\260\354\274\223\353\252\254/kyuhyun.py" | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 "[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" diff --git "a/[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" "b/[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" new file mode 100644 index 00000000..ada5a853 --- /dev/null +++ "b/[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" @@ -0,0 +1,11 @@ +def solution(nums): + answer = {} + + pokemon_num = len(nums) // 2 + + for i in range(len(nums)) : + answer[nums[i]] = "new pokemon!" + if len(answer) == pokemon_num: + return len(answer) + + return len(answer) From 2eb0a441532959e83bcb595368ec09b5f012256a Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Mon, 30 Jan 2023 12:33:43 +0900 Subject: [PATCH 2/9] =?UTF-8?q?Create=20=ED=8F=B0=EC=BC=93=EB=AA=AC=20kyuh?= =?UTF-8?q?yun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../\355\217\260\354\274\223\353\252\254/kyuhyun.py" | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename "[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" => "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\217\260\354\274\223\353\252\254/kyuhyun.py" (100%) diff --git "a/[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\217\260\354\274\223\353\252\254/kyuhyun.py" similarity index 100% rename from "[Programmers - \352\263\240\353\223\235\354\240\220 Kit]/\355\217\260\354\274\223\353\252\254/kyuhyun.py" rename to "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\217\260\354\274\223\353\252\254/kyuhyun.py" From a3bf4835931cd13c290f7d9c47c0cb20f466f350 Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Mon, 30 Jan 2023 15:42:52 +0900 Subject: [PATCH 3/9] =?UTF-8?q?Create=20=ED=8F=B0=EC=BC=93=EB=AA=AC=20kyuh?= =?UTF-8?q?yun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../kyuhyun.py" | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\217\260\354\274\223\353\252\254/kyuhyun.py" => "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\225\264\354\213\234_\355\217\260\354\274\223\353\252\254/kyuhyun.py" (100%) diff --git "a/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\217\260\354\274\223\353\252\254/kyuhyun.py" "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\225\264\354\213\234_\355\217\260\354\274\223\353\252\254/kyuhyun.py" similarity index 100% rename from "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\217\260\354\274\223\353\252\254/kyuhyun.py" rename to "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\225\264\354\213\234_\355\217\260\354\274\223\353\252\254/kyuhyun.py" From 3a290e4a777bab1505f25a704d0e93004996e964 Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Mon, 30 Jan 2023 15:44:34 +0900 Subject: [PATCH 4/9] =?UTF-8?q?Create=20=EC=98=AC=EB=B0=94=EB=A5=B8=20?= =?UTF-8?q?=EA=B4=84=ED=98=B8=20kyuhyun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../kyuhyun.py" | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" diff --git "a/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" new file mode 100644 index 00000000..a5d54f19 --- /dev/null +++ "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" @@ -0,0 +1,19 @@ +def solution(s): + x = len(s) + stack = [] + + for i in range(x): + key = s[i] + + if key == ")": + if len(stack) == 0: + return False + else: + stack.pop() + else: + stack.append(key) + + if len(stack) == 0: + return True + return False + From 6966d13500537875d56e9e1db32daecc2fe44c99 Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Tue, 31 Jan 2023 00:33:39 +0900 Subject: [PATCH 5/9] =?UTF-8?q?Create=20=EA=B0=99=EC=9D=80=20=EC=88=AB?= =?UTF-8?q?=EC=9E=90=EB=8A=94=20=EC=8B=AB=EC=96=B4=20kyuhyun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../kyuhyun.py" | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 "Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \352\260\231\354\235\200 \354\210\253\354\236\220\353\212\224 \354\213\253\354\226\264/kyuhyun.py" diff --git "a/Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \352\260\231\354\235\200 \354\210\253\354\236\220\353\212\224 \354\213\253\354\226\264/kyuhyun.py" "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \352\260\231\354\235\200 \354\210\253\354\236\220\353\212\224 \354\213\253\354\226\264/kyuhyun.py" new file mode 100644 index 00000000..9e85b65e --- /dev/null +++ "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \352\260\231\354\235\200 \354\210\253\354\236\220\353\212\224 \354\213\253\354\226\264/kyuhyun.py" @@ -0,0 +1,10 @@ +def solution(arr): + answer = [] + + answer.append(arr[0]) + + for i in range(len(arr)): + if answer[-1] != arr[i]: + answer.append(arr[i]) + + return answer From 3ab199ba81f3761488989bdf3410d84a2b881b25 Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Tue, 31 Jan 2023 00:34:40 +0900 Subject: [PATCH 6/9] =?UTF-8?q?Create=20=EC=98=AC=EB=B0=94=EB=A5=B8=20?= =?UTF-8?q?=EA=B4=84=ED=98=B8=20kyuhyun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../kyuhyun.py" | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" => "Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" (100%) diff --git "a/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" similarity index 100% rename from "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\354\212\244\355\203\235&\355\201\220_\354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" rename to "Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\354\212\244\355\203\235-\355\201\220] \354\230\254\353\260\224\353\245\270 \352\264\204\355\230\270/kyuhyun.py" From 92183c8389d5e302745b381fc28917e314ea936e Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Tue, 31 Jan 2023 00:36:10 +0900 Subject: [PATCH 7/9] =?UTF-8?q?Create=20=ED=8F=B0=EC=BC=93=EB=AA=AC=20kyuh?= =?UTF-8?q?yun.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../kyuhyun.py" | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\225\264\354\213\234_\355\217\260\354\274\223\353\252\254/kyuhyun.py" => "Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\355\225\264\354\213\234] \355\217\260\354\274\223\353\252\254/kyuhyun.py" (100%) diff --git "a/Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\225\264\354\213\234_\355\217\260\354\274\223\353\252\254/kyuhyun.py" "b/Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\355\225\264\354\213\234] \355\217\260\354\274\223\353\252\254/kyuhyun.py" similarity index 100% rename from "Programmers - \352\263\240\353\223\235\354\240\220 Kit/\355\225\264\354\213\234_\355\217\260\354\274\223\353\252\254/kyuhyun.py" rename to "Programmers - \352\263\240\353\223\235\354\240\220 Kit/[\355\225\264\354\213\234] \355\217\260\354\274\223\353\252\254/kyuhyun.py" From c7d9d9a5154561d05fe2744e7bec23cb8acb7d16 Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Tue, 31 Jan 2023 00:37:27 +0900 Subject: [PATCH 8/9] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 48a8cba5..7c214f94 100644 --- a/README.md +++ b/README.md @@ -71,7 +71,7 @@ ex) Update README.md - 매일 다른 카테고리 문제를 선별하여 풀기 / 약 20일 소요 예상 -- Day1 | [폰켓몬 #1](https://github.com/da-in/algorithm-study/issues/1), [올바른 괄호 #2](https://github.com/da-in/algorithm-study/issues/2) +- Day4 | [폰켓몬 #1](https://github.com/da-in/algorithm-study/issues/1), [올바른 괄호 #2](https://github.com/da-in/algorithm-study/issues/2), [같은 숫자는 싫어](https://github.com/da-in/algorithm-study/issues/30)
### Programmers From 9e67b3f80d049ba3ffdbf001afced39b07fb4706 Mon Sep 17 00:00:00 2001 From: lalabulla <102718303+lalabulla@users.noreply.github.com> Date: Tue, 31 Jan 2023 00:38:34 +0900 Subject: [PATCH 9/9] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7c214f94..2c931358 100644 --- a/README.md +++ b/README.md @@ -71,7 +71,7 @@ ex) Update README.md - 매일 다른 카테고리 문제를 선별하여 풀기 / 약 20일 소요 예상 -- Day4 | [폰켓몬 #1](https://github.com/da-in/algorithm-study/issues/1), [올바른 괄호 #2](https://github.com/da-in/algorithm-study/issues/2), [같은 숫자는 싫어](https://github.com/da-in/algorithm-study/issues/30) +- Day4 | [폰켓몬 #1](https://github.com/da-in/algorithm-study/issues/1), [올바른 괄호 #2](https://github.com/da-in/algorithm-study/issues/2), [같은 숫자는 싫어 #30](https://github.com/da-in/algorithm-study/issues/30)
### Programmers