-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathgroups.py
28 lines (24 loc) · 1.01 KB
/
groups.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
root = "database/"
def add(name, members):
f = open(root + name + ".txt", "a")
f.write("members: " + members + "\n")
f.close()
def rank(name):
f = open(root + name + ".txt", "a")
creativity = input("creativity: ")
complexity = input("complexity: ")
efficiency = input("efficiency: ")
execution = input("execution: ")
appearance = input("appearance: ")
f.write("creativity: " + creativity + "\n")
f.write("complexity: " + complexity + "\n")
f.write("efficiency: " + efficiency + "\n")
f.write("execution: " + execution + "\n")
f.write("appearance: " + appearance + "\n")
numCreativity = float(creativity)
numComplexity = float(complexity)
numEfficiency = float(efficiency)
numExecution = float(execution)
numAppearance = float(appearance)
composite = (0.05 * numCreativity) + (0.3 * numComplexity) + (0.3 * numEfficiency) + (0.3 * numExecution) + (0.05 * numAppearance)
f.write("composite: " + str(composite) + "\n")