---
# System prepended metadata

title: '2024/02/06(二) 每週 21:00 Codewars 刷題'
tags: [Mentocamp3 刷題讀書會]

---

---
tags: Mentocamp3 刷題讀書會
---

#  2024/02/06(二) 每週 21:00 Codewars 刷題

## 題目
-  主要：[Codewars_7kyu Two to One](https://www.codewars.com/kata/5656b6906de340bd1b0000ac/train/python) 
-  次要：[LeetCode_easy 217. Contains Duplicate](https://leetcode.com/problems/contains-duplicate/description/) 

> ## 會後Keynote (大家有用到的方法)
> ### Python
> - **Set** : 不重複序列 set()
>     - https://www.runoob.com/python3/python3-set.html
>     - https://codeshiba.com/m3/python-x-js#%E7%8D%A8%E4%B8%80%E7%84%A1%E4%BA%8C%E7%9A%84-%E9%9B%86%E5%90%88-set
>- **Sort** : 排序
>     - https://www.runoob.com/python/python-func-sorted.html
> - **Join** : 將陣列內元素合併為字串
>     - https://www.delftstack.com/zh-tw/howto/python/how-to-convert-a-list-to-string/
> ### Javascript
> - **字串轉陣列**
>      - 展開運算子Spread Operator
>      ``` JavaScript
>      let str = "hello";
>      let arr = [...str]; // ['h', 'e', 'l', 'l', 'o']
>      ``` 
>      - split()
>      ``` JavaScript
>      let str = "hello";
>      let arr = str.split(""); // ['h', 'e', 'l', 'l', 'o']
>      ```
>      - Array.from()
>      ```JavaScript
>      let str = "hello";
>      let arr = Array.from(str); // ['h', 'e', 'l', 'l', 'o']
>      ```
> - **Set** : 儲存任何類型的唯一值 new Set()
>     - https://developer.mozilla.org/zh-TW/docs/Web/JavaScript/Reference/Global_Objects/
> - **Sort** : 將陣列排序 (要注意續對象)
>     - https://developer.mozilla.org/zh-TW/docs/Web/JavaScript/Reference/Global_Objects/Array/sort
> - **Join** : 將陣列中所有的元素連接、合併成一個字串，並回傳此字串
>     - https://developer.mozilla.org/zh-TW/docs/Web/JavaScript/Reference/Global_Objects/Array/join



## 回報格式

- 請 Fork 此 Replit 連結，進行程式碼解題，完成後將連結貼至「解題分享區」來與大家交流做法。
    - Python: https://replit.com/@AnnaChu1/CodewarsTwo-to-One
    - JS: https://replit.com/@AnnaChu1/CodewarsTwo-to-Onejs#index.js
- 一定要Fork到自己帳號底下，否則我印象中程式碼會不見。
 (Fork過程有錯誤或不懂的，可以再讓我知道喔！)




![截圖 2024-01-24 晚上8.33.32](https://hackmd.io/_uploads/BysLiq0Fp.png)


![截圖 2024-01-24 晚上8.33.45](https://hackmd.io/_uploads/rypUicRta.png)




解題分享區
---
#### 讀書會議流程：

1. 題目說明
2. 題目解析
4. 成員分享解題思路
5. 問題與討論


#### 回報區 ：

<No.1> Anna
Replit：https://replit.com/@AnnaChu1/Codewars-Isograms

<No.2> 阿媜
Replit：https://replit.com/@selena60635/CodewarsTwo-to-Onejs#index.js

<No.3> Jamie
Replit：https://replit.com/@Jamie-22/CodewarsTwo-to-One#main.py

<No.4> Alvin
Replit：https://replit.com/@yangalvin207/CodewarsTwo-to-One20240206#main.py

<No.5> Lin
Replit：https://replit.com/@shower112024/CodewarsTwo-to-One?run=true#main.py

<No.6> 明達
Substack : https://jackdatsai.substack.com/p/217-contains-duplicate

<No.7> 宗承
Substack : https://replit.com/@love970120/CodewarsTwo-to-Onejs?v=1#index.js

<No.8> Ally
Replit: https://replit.com/@a2623212/CodewarsTwo-to-Onejs

<No.9> Carol
Replit: https://replit.com/@codasobi/MotionlessVoluminousLocus#main.py
...請依序貼上
