This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Investment simulation on FIIs over years | |
import math | |
import matplotlib.pyplot as plt | |
import locale | |
locale.setlocale(locale.LC_ALL, '') | |
# FII | |
price = 10 | |
dividends = 0.08 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# * Keyboad autocomplete * | |
set show-all-if-ambiguous on | |
if [ -f `brew --prefix`/etc/bash_completion.d/git-completion.bash ]; then | |
. `brew --prefix`/etc/bash_completion.d/git-completion.bash | |
fi | |
# * Customizing PS1 - Add Battery Percentage * | |
# get_battery() { | |
# acpi | egrep -o '([0-9]+)%' | |
# } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# WS client example | |
import asyncio | |
import websockets | |
import time | |
async def receive(): | |
uri = "ws://localhost:9999" | |
async with websockets.connect(uri) as websocket: |
NewerOlder