I hereby claim:
- I am srikumarks on github.
- I am srikumarks (https://keybase.io/srikumarks) on keybase.
- I have a public key ASDxkdOO0jW8Il1zHH4CO79kv6lEx4tXYvlOA9CosHx7WAo
To claim this, I am signing this object:
import re | |
from pypdf import PdfReader | |
import pandas as pd | |
# 34ca61ebc3ddbb71a1d16f8f43db38d031872126 encashment-details.pdf | |
encashment = PdfReader("encashment-details.pdf") | |
# 11e0aff1007065d9a4de49ac5499fbf4186dcda0 purchaser-details.pdf | |
purchaser = PdfReader("purchaser-details.pdf") |
function mandelbrot_kernel(c, max_iter) | |
z = c | |
for i in 1:max_iter | |
z = z * z + c | |
if abs2(z) > 4 | |
return i-1 | |
end | |
end | |
return max_iter |
using Dates, TimeZones, SatelliteToolbox | |
""" | |
upcoming_birthpos gives you the exact time and date within the | |
next year, at which the earth arrives again closest to where it | |
was when you were born (relative to the sun). It also gives | |
this minimum distance value in km. | |
""" | |
function upcoming_birthpos(y,m,d,h,min,s,tzstr="Asia/Kolkata") | |
dob = ZonedDateTime(y,m,d,h,min,s,0,TimeZone(tzstr)) |
:- module(qd, [gendata/0, nth/5, weekday/2, direction/2, dayprop/2, today/1, gendates/4, leapyear/1, nonleapyear/1, validate/1, cardinal/3]). | |
:- use_module(library(clpfd)). | |
% This module defines a small query language for (approximate) dates according | |
% to the gregorian calendar. You can run this program using -- | |
% swipl -t gendata datelang.pl | |
% Abstract | |
% ======== |
using DataStructures | |
# Ref: https://github.com/renatoathaydes/prechelt-phone-number-encoding | |
# This is a straight translation of Norvig's program into Julia. | |
# Function for function it is a straight port. | |
mappings = [("eE",0),("jnqJNQ",1),("rwxRWX",2),("dsyDSY",3),("ftFT",4),("amAM",5), | |
("civCIV",6),("bkuBKU",7),("lopLOP",8),("ghzGHZ",9)] | |
char2num = Dict((l,d) for (s,d) in mappings for l in s) |
// Usage is like - | |
// | |
// let x = await task(obj, obj.method, arg1, arg2); | |
// do_something(x); | |
// | |
// where obj.method is a method that takes a NodeJS style callback | |
// as the last argument, which is left out when making the above call. | |
// The task function turns the callback backed function into a | |
// pseudo promise which the async/await mechanism can work with. | |
function task(target, fn, ...argv) { |
I hereby claim:
To claim this, I am signing this object:
// metric = array of real numbers (like > 100 or something) | |
// IQR = inter-quaartile-range | |
function numBins(metric, defaultBins) { | |
var h = binWidth(metric), ulim = Math.max.apply(Math, metric), llim = Math.min.apply(Math, metric); | |
if (h <= (ulim - llim) / metric.length) { | |
return defaultBins || 10; // Fix num bins if binWidth yields too small a value. | |
} | |
return Math.ceil((ulim - llim) / h); | |
} |
var sharpLabels = ["A", "A♯", "B", "C", "C♯", "D", "D♯", "E", "F", "F♯", "G", "G♯"]; | |
var flatLabels = ["A", "B♭", "B", "C", "D♭", "D", "E♭", "E", "F", "G♭", "G", "A♭"]; | |
function pitchClass(freq_Hz, labels) { | |
var cents = Math.round(1200 * Math.log(freq_Hz/440) / Math.log(2)); | |
var semitones = Math.round(cents / 100); | |
var pclass = (((semitones % 12) + 12) % 12); | |
var octave = 4 + Math.floor(semitones / 12); |