I hereby claim:
- I am jseam2 on github.
- I am jseam (https://keybase.io/jseam) on keybase.
- I have a public key whose fingerprint is E9EA 85C8 0452 7CF0 3A09 BFAA BEFB D1C8 CCCF E445
To claim this, I am signing this object:
def any_win(win_num, additional, my_num): | |
""" | |
Check if there's a win | |
:param win_num: the winning numbers (list of int) | |
:param addtional: additional number (int) | |
:param my_num: my numbers (list of int) | |
:return: Top Category of Win or No Win (str) | |
""" | |
# temporary list |
I hereby claim:
To claim this, I am signing this object:
import java.util.ArrayList; | |
public class Hailstone{ | |
public static void main(String[] args){ | |
System.out.println(Hail(3)); | |
} | |
public static ArrayList Hail(int n){ | |
ArrayList<Integer> HS = new ArrayList<Integer>(); | |
HS.add(n); | |
# -*- coding: utf-8 -*- | |
""" | |
no difference | |
""" | |
import time | |
import matplotlib.pyplot as plt | |
table = {0:1} | |
def fact1(n): | |
if n in table: |
""" | |
fib iterative version | |
with memoization | |
""" | |
def fib(n): | |
a, b = 0, 1 | |
for x in range(1, n + 1): | |
a, b = b, a+b | |
return a |
""" | |
Add file name to the bottom of pdf page using python | |
""" | |
from PyPDF2 import PdfFileWriter, PdfFileReader | |
import io | |
from reportlab.pdfgen import canvas | |
from reportlab.lib.pagesizes import letter | |
import os | |
import sys |
/* | |
* ===================================================================================== | |
* | |
* Filename: complex.c | |
* | |
* Description: Implementation of program that supports accepting two complex numbers from the user; adding, subtracting, multiplying, and dividing them; reporting each result to the user | |
* | |
* Version: 1.0 | |
* Created: 02/08/2018 10:12:01 PM | |
* Revision: none |
import random | |
""" | |
Using an unbiased 6 sided die | |
What is the probability that you will roll a 4 at | |
least once if you roll six times? | |
P(At Least a 4) = P(Total) - P(Not a 4)^6 | |
P(At Least a 4) = 1 - (5/6)^6 |
import random | |
# As the grammar doesn't handle divide by 0, such functions cannot be evaluated | |
# properly | |
def calculator(input_string): | |
""" | |
Input a string with valid grammer to calculate result | |
We will use the following grammar |
Sub PasswordBreaker() | |
Dim i As Integer, j As Integer, k As Integer | |
Dim l As Integer, m As Integer, n As Integer | |
Dim i1 As Integer, i2 As Integer, i3 As Integer | |
Dim i4 As Integer, i5 As Integer, i6 As Integer | |
On Error Resume Next | |
For i = 65 To 66: For j = 65 To 66: For k = 65 To 66 |