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
from lxml import html | |
import requests, os | |
wowhead = "http://www.wowhead.com/item=" | |
wantedStats = ['Agility or Strength or Intellect', 'Strength', 'Agility', 'Intellect', 'Attack Power', 'Spell Power', 'Haste', 'Critical Strike', 'Mastery', 'Versatility', 'Multistrike'] | |
def getItemNumber(itemNumber=114979): | |
if itemNumber == 114979: | |
itemNumber = raw_input("Please enter the item number you wish to test:\n\t") |
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
function checkNested(obj /*, level1, level2, ... levelN*/) { | |
var args = Array.prototype.slice.call(arguments, 1); | |
for (var i = 0; i < args.length; i++) { | |
if (!obj || !obj.hasOwnProperty(args[i])) { | |
return false; | |
} | |
obj = obj[args[i]]; | |
} |
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
median = 0 | |
if len(stats)%2 == 0: | |
median = (stats[len(stats)/2] + stats[len(stats)/2]) / 2 | |
else: | |
stats[len(stats)/2] + 1 |
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
. Nutrition: the science of food, the nutrients and other substances therein, their action, interaction and balance in relation to health and disease, and the processes by which the organism ingests, absorbs, transports, utilizes and excretes food substances (Nutrition and Diet Therapy Reference, 1996).In order to get a further understanding of nutrition, describing nutrients is necessary as well as their purpose and function. According to the British Nutrition Foundation’s (BNF) website, a nutrient provides energy or a source for growth and maintenance of the body. Nutrients are categorized by macro- and micro-nutrients. | |
Macronutrients include carbohydrates, orotein, and fats. The BNF declares these are the nutrients organisms need the largest amounts of as they are responsible for energy and growth and maintenance. Micronutrients are essentials that are not needed in as large amounts, such as vitamins and minerals.It is important to note that not all vital components of a healthy diet are defined as a nut |
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
if dndPlayers[vindex]['shield'] > 0: | |
if dndPlayers[vindex]['shield'] >= damage: | |
dndPlayers[vindex]['shield'] -= damage | |
victim.health += damage | |
playerMessage(vindex, 'Your shield blocked %s damage'%damage) | |
else: | |
victim.health += dndPlayers[vindex]['shield'] | |
playerMessage(vindex, 'Your shield blocked %s damage and is now depeleted'%dndPlayers[vindex]['shield']) | |
dndPlayers[vindex]['shield'] = 0 |
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
/* Aurora Pariseau | |
Floating point arithmetic | |
*/ | |
import java.util.*; | |
class main | |
{ | |
public static void main (String args[]) | |
{ |
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
def checkPred(myString): | |
predicates = 0 | |
for line in myString: | |
myLine = line | |
while "//" in myLine: | |
myLine = line.split("//")[0] # Gets the part of the string BEFORE "//" | |
words = [] | |
for word in myLine: |
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 xlrd | |
import os | |
path = "C:\\users\\nx7233pl\\Documents\\school\\STAT210\\" | |
output = path + "bike-stops.txt" | |
book = xlrd.open_workbook(path + "citibike-concat-stops.xlsx") | |
print(book.sheet_names()) # [] | |
sheet = book.sheet_by_index(0) # Index out of bounds | |
firstCell = (1,16) |
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
; 2^i * Y | |
MOV R5, R4 | |
TSTR4: TST R4 | |
BEQ TSTSUB | |
ASL R2 ; ASL for DP is SHIFT HIGH, then ADC | |
ASL R3 ; Y is DP | |
ADC R2 | |
DEC R4 | |
BR TSTR4 |
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
CLR R5 | |
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 N 0 | |
Z 0 | |
V 0 | |
C 0 | |
SEC | |
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 N 0 | |
Z 0 |
OlderNewer