일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 | 31 |
Tags
- 컴퓨터의 구조
- DWG
- 43. Multiply Strings
- 파이썬
- 315. Count of Smaller Numbers After Self
- Python Implementation
- 밴픽
- Python
- attribute
- kaggle
- Decorator
- 시바견
- t1
- concurrency
- Substring with Concatenation of All Words
- LeetCode
- 715. Range Module
- data science
- 30. Substring with Concatenation of All Words
- 109. Convert Sorted List to Binary Search Tree
- 운영체제
- Protocol
- iterator
- Regular Expression
- Generator
- shiba
- Convert Sorted List to Binary Search Tree
- 프로그래머스
- Class
- Python Code
Archives
- Today
- Total
목록first-order function (1)
Scribbling
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/dV7FQw/btrxiGPaIsU/t1vZ7o39YNcPFli38LEkAK/img.png)
Some traditional design patterns can be simplified by making good use of first-order functions in python. Let's see the below example. 1. Goal: Calculate total price and discount for each order 2. There are three discount strategies; - fidelitypromo: if the customer's fidelity >= 1000, then 5% of the total - bulkitempromo: if q >= 20 for an item, then 10% of the item - largeorderpromo: if type >..
Computer Science/Python
2022. 3. 25. 15:34