From 4294539280cf58ff49cbb16c1204d4591a6e0f2c Mon Sep 17 00:00:00 2001 From: huisuu Date: Tue, 14 May 2024 23:20:30 +0900 Subject: [PATCH] 3.py --- HSKIM/1to10/3.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 HSKIM/1to10/3.py diff --git a/HSKIM/1to10/3.py b/HSKIM/1to10/3.py new file mode 100644 index 0000000..1f8be94 --- /dev/null +++ b/HSKIM/1to10/3.py @@ -0,0 +1,12 @@ +def solution(numbers): + sum = [] + num = 0 + l = len(numbers) + + for i in range(0, l): + for j in range(0, l): + num = numbers[i] + numbers[j] + if i != j: + sum.append(num) + lst = list(set(sum)) + return lst \ No newline at end of file