Skip to content

Instantly share code, notes, and snippets.

View cedrickvstheworld's full-sized avatar
:octocat:
up to no good

cedrickvstheworld

:octocat:
up to no good
View GitHub Profile
from tkinter import *
from tkinter import ttk
from tkinter import messagebox as mbox
from matplotlib.figure import Figure
from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg
class Frame:
def __init__(self, root, framename, framelabel, col, row):
self.root = root
from tkinter import *
from tkinter import ttk
from math import *
calc = Tk()
calc.title('Calculator 1.0')
calc.resizable(0, 0)
# functions
@cedrickvstheworld
cedrickvstheworld / wholenumtoromannum.py
Last active June 12, 2018 09:03
whole number to roman numerals
def whtornb(j):
oned = {'1': 'I', '2': 'II', '3': 'III', '4': 'IV', '5': 'V',
'6': 'VI', '7': 'VII', '8': 'VIII', '9': 'IX', '0': ''}
twod = {'1': 'X', '2': 'XX', '3': 'XXX', '4': 'XL', '5': 'L',
'6': 'LX', '7': 'LXX', '8': 'LXXX', '9': 'XC', '0': ''}
threed = {'1': 'C', '2': 'CC', '3': 'CCC', '4': 'CD', '5': 'D',
'6': 'DC', '7': 'DCC', '8': 'DCCC', '9': 'CM', '0': ''}