Skip to content

Instantly share code, notes, and snippets.

View goatandsheep's full-sized avatar
⛸️
carving my own path

Kemal Ahmed goatandsheep

⛸️
carving my own path
View GitHub Profile
"""
Question
Stan is looking to provide access to creators' calendars and enable fans to book meetings with them.
Your assignment is to create an algorythm that will assess creator's calendar and return available slots
for fans to book.
"""
# TODO: add functionality for 30 minutes of precision
def fetch_available_slots(duration, events):
@goatandsheep
goatandsheep / Texify-Mathjax.js
Last active March 6, 2023 07:57
[Deprecated] A Tampermonkey / Greasemonkey script that turns LaTeX code on page into mathematical symbols using MathJax
// ==UserScript==
// @name TeXify the World MathJax
// @namespace
// @version 1.0
// @description Enables MathJax to process LaTeX on all websites. Based off SOUP (Stack Overflow Unofficial Patch) and http://www.math.ucla.edu/~robjohn/math/mathjax.html.
// @include *
// @copyright
// ==/UserScript==
/*
var mathjaxVersion = "http://cdn.mathjax.org";
<script
data-id-pool="us-east-1:abcd1234-abcd-1234-5678-abcd12345678"
data-pinpoint-id="1234abcd5678abcd7890abcd1234"
id="aws-web-analytics"
src="https://goatandsheep.github.io/aws-web-analytics/dist/aws-web-analytics.js"
type="text/javascript"
></script>
PassengerId Survived
892 0
893 1
894 0
895 0
896 1
897 0
898 1
899 0
900 1
## Do not do this
#if(${context.identity.username} != ${context.result.parentId})
$utils.unauthorized()
#else
null
#end
#if(${context.identity.username} != ${context.arguments.parentId})
$utils.unauthorized()
#else
{
"version" : "2017-02-28",
"operation" : "UpdateItem",
"key" : {
"childId": $util.dynamodb.toDynamoDBJson($ctx.args.childId),
"parentId": $util.dynamodb.toDynamoDBJson($ctx.identity.username)
},

What I learned in a month as a manager

Two months ago, I was working on a project that felt completely mismanaged and didn't meet the expectations. The project had an extremely tight deadline and we were using new technologies we'd never used before.

Plans were constantly changing and it felt extremely hard to keep up. It seemed like there was a lot of broken telephone. Re-delegation of tasks encouraged there to be more than 5 managers of the project making for an issue of "bubbling concerns" where concerns needed to be raised to multiple people and missing one could be catastrophic. I was exempted from meetings with decision-making including some that were only held in person, missing key details.

Our team of 2 had high expectations, but were still split into 2 teams of 1 to distrubute our efforts across multiple platforms, one of which we'd never used before. PTO also happened to coincide with the last weeks of the project for many key members.

A designer joined the mix late in the game and views were

Auth.currentCredentials().then(creds => {
Analytics.autoTrack('pageView', {
// REQUIRED, turn on/off the auto tracking
enable: true,
// OPTIONAL, the event name, by default is 'pageView'
eventName: 'pageView',
// OPTIONAL, the attributes of the event, you can either pass an object or a function
// which allows you to define dynamic attributes
// attributes: {
// attr: 'attr'
LANG=C sed 's/,/\\,/g' input.dat > input.dat
LANG=C sed 's/::/,/g' input2.dat > output.csv
  1. Respect Recipients' Time: This is the fundamental rule. As the message sender, the onus is on YOU to minimize the time your email will take to process. Even if it means taking more time at your end before sending.

  2. Short or Slow is not Rude: Let's mutually agree to cut each other some slack. Given the email load we're all facing, it's OK if replies take a while coming and if they don't give detailed responses to all your questions. No one wants to come over as brusque, so please don't take it personally. We just want our lives back!

  3. Celebrate Clarity: Start with a subject line that clearly labels the topic, and maybe includes a status category [Info], [Action], [Time Sens] [Low Priority]. Use crisp, muddle-free sentences. If the email has to be longer than five sentences, make sure the first provides the basic reason for writing. Avoid strange fonts and colors.

  4. Quash Open-Ended Questions: It is asking a lot to send someone an email with four long paragraphs of turgid text foll