See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope> is optional
| """ | |
| Copy and paste any shape using space and '|', add an '*' to indicate the end of your stream | |
| example input: | |
| || || | |
| || || || | |
| || || || | |
| ||| |||* | |
| STart each line with at least one space and make sure your shape is no more than 60 characters in width to maintain general ASCII range | |
| """ | |
| import re |
| # 1) Create a middlewares/middlewares.py file and copy this: | |
| import threading | |
| class RequestMiddleware: | |
| def __init__(self, get_response, thread_local=threading.local()): | |
| self.get_response = get_response | |
| self.thread_local = thread_local | |
| # One-time configuration and initialization. |
Page 47
This kind of mindset is crucial to managing your career, because when you start to think of yourself as a business, you start to make good business decisions.
Page 52
Every step you take without a clear direction is a wasted step. Don’t randomly walk through life without a purpose for your career.
Your big goal should be something not too specific, but clear enough that you can know if you’re steering toward it or not. Think about what you want to ultimately do with your career.
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
| def fizzbuzz(n): | |
| if n % 3 == 0 and n % 5 == 0: | |
| return 'FizzBuzz' | |
| elif n % 3 == 0: | |
| return 'Fizz' | |
| elif n % 5 == 0: | |
| return 'Buzz' | |
| else: | |
| return str(n) |