Skip to content

Instantly share code, notes, and snippets.

View chadman's full-sized avatar

Chad Meyer chadman

View GitHub Profile
private T ActionWithRetry<T>(Func<T> fn) {
int retryCount = 0;
bool success = false;
while (retryCount < 4 && !success) {
try {
return fn();
}
catch (Exception e) {
retryCount++;
@chadman
chadman / gist:1180f830fd4a2392c4e8
Created November 7, 2015 04:17
Given a specific amount of money on hand, calculate the CC bills to pay off to save the most amount of money a month
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace budget {
public class Program {
static void Main(string[] args) {
var debt = new DebtCalculation(500);
@chadman
chadman / delete_branch
Created July 25, 2012 17:42
Deleting a branch
git push origin :[branchname]
git branch -D [branchname]