This file contains hidden or 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
import { maxSubArray, addToSet } from './max-sub-array.airbnb' | |
describe('MaxSubArray', () => { | |
let arr = [] | |
test('should return on empty array', () => { | |
expect(maxSubArray(arr)).toBeUndefined() | |
}) | |
test('should work on array.length === 1', () => { |
This file contains hidden or 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
import * as React from 'react' | |
import { PayPalButton } from 'react-paypal-button-v2' | |
import Typography from '@material-ui/core/Typography' | |
import { PAYMENT_GATEWAYS, YG_EMAIL_BASE } from 'config' | |
import { Checkout as CheckoutInterface } from 'lib/queries/generatedTypes/Checkout' | |
interface PaypalOrderParams { |
This file contains hidden or 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
//This problem was asked by Google. | |
//Given a string, return the length of the longest palindromic subsequence in the string. | |
//For example, given the following string: | |
// input:: MAPTPTMTPA | |
//Return 7, since the longest palindromic subsequence in the string is APTMTPA. | |
//Recall that a subsequence of a string does not have to be contiguous! |
This file contains hidden or 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
#!/bin/sh | |
# Just copy and paste the lines below (all at once, it won't work line by line!) | |
# MAKE SURE YOU ARE HAPPY WITH WHAT IT DOES FIRST! THERE IS NO WARRANTY! | |
function abort { | |
echo "$1" | |
exit 1 | |
} | |
set -e |