This file contains 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
#!/usr/bin/env python3 | |
################################################################ | |
# Hardhat Gas Report Diff | |
# ============================================================== | |
# Steps: | |
# 1) Have `hardhat-gas-reporter` | |
# 2) Run `npx hardhat test` before and after applying | |
# some change to the smart contracts you're testing | |
# 3) Save the gas reports into separate files (e.g. |
This file contains 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
#!/usr/bin/env python3 | |
import random | |
from colorama import Fore | |
hiraganas = { | |
"あ": "a", | |
"い": "i", | |
"う": "u", | |
"え": "e", |
This file contains 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
#!/usr/bin/env bash | |
set -euo pipefail | |
[ $# -ge 1 ] || (echo "Expected URI for git clone" >&2 && exit 1) | |
repodir=`mktemp -d` | |
git clone -- "$1" "$repodir" | |
pushd "$repodir" >/dev/null | |
folders=`git ls-files | xargs -r -d '\n' -n1 dirname | sort | uniq | xargs -r -d '\n' -n1 basename` | |
popd >/dev/null | |
rm -rf "$repodir" | |
snake_case=`echo "$folders" | grep -- '_' | tee snake | wc -l` |
This file contains 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
<html> | |
<head> | |
<title>Horário das aulas</title> | |
<style> | |
table, th, td { | |
border: 1px solid black; | |
border-collapse: collapse; | |
padding: 10px; | |
} | |
table { |
This file contains 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
/* | |
* bernoulli.c | |
* | |
* Bernoulli distribution simulation | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <assert.h> |
This file contains 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
/* | |
* pi.c | |
* | |
* Approximation of Pi by the probability | |
* of a point to fall into the circle of | |
* a circumscribed square in the xy-plane. | |
* | |
* Inspired by Simulation Fifth Edition | |
* Book by Sheldon Ross | |
*/ |
This file contains 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
/* | |
* pow.c | |
* | |
* Optimised power function for integer values | |
*/ | |
#include <assert.h> | |
#include <stdio.h> | |
#include <stdint.h> | |
#include <stdlib.h> |
This file contains 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
/* | |
* perm.c | |
* | |
* Array permutation | |
*/ | |
#include <assert.h> | |
#include <stdio.h> | |
#include <time.h> | |
#include <stdlib.h> |
This file contains 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 urllib.request | |
import xlrd | |
import tkinter as tk | |
from tkinter import filedialog | |
# ############################################ | |
# PUC Dependency Graph Viewer | |
# ############################################ | |
# Guilherme Dantas, 7/23/2019 | |
# ############################################ |
This file contains 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 javax.swing.*; | |
import java.math.*; | |
public class HelloWorld{ | |
public static void main(String args[]){ | |
double delta,a,b,c,x1,x2; | |
String vat; //vat=Valor ATual | |
JOptionPane.showMessageDialog(null,"Bem-vindo ao calculador de equação do 2º grau!"); | |
vat = JOptionPane.showInputDialog("Insira o coeficiente a"); |