Skip to content

Instantly share code, notes, and snippets.

from dataclasses import dataclass
from typing import Dict, List
@dataclass
class Item:
name: str
price: float
quantity: int
shared_by: List[str] # List of names of people sharing the item
# Bain Fund
# FV = projected cash flow for each year (amount you expect to receive)
# n = number of periods out the cash flow is from the present
def present_value(FV, n, discount_rate=.1):
return FV/((1 + discount_rate)**n)
if __name__ == "__main__":
gross_rates_of_return = [.05, .15, .25, .35, .45]
fund_start_size = 200000000 # 200 million
@MarcoF1
MarcoF1 / io_uring-echo-server.c
Last active May 19, 2022 14:02
io_uring-echo-server
/**/
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <string.h>
#include <strings.h>
#include <errno.h>
#include <sys/time.h>
#include <sys/resource.h>
@MarcoF1
MarcoF1 / resume.json
Last active November 15, 2020 00:58
My Resume as a JSON exported from LinkedIn
{
"meta": { "theme": "elegant" },
"$schema": "https://json.schemastore.org/resume",
"basics": {
"name": "Marco Fleming",
"label": "MIT '22",
"image": "https://media-exp1.licdn.com/dms/image/C4D03AQE5njKHL5CtVA/profile-displayphoto-shrink_200_200/0?e=1609977600&v=beta&t=O88WFSw3CY0LaIhk-DDO4ZwzesW9EvZBbdhTm7EFhHE",
"email": "marcof@mit.edu",
"phone": "(956) 330-7839",
"url": "marcof.dev",