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 java.util.jar.Attributes.Name; | |
public class Candidate implements CandidateInterface{ | |
private String firstName; | |
private String lastName; | |
private int voteCount; | |
public Candidate(String inFirstName, String inLastName){ | |
firstName = inFirstName; | |
lastName = inLastName; |
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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" /> | |
<title>Results</title> | |
</head> | |
<body> | |
<?php | |
/* | |
Lab 5 |
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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" /> | |
<title>Results</title> | |
</head> | |
<body> | |
<?php | |
/* | |
Lab 5 |
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 java.util.ArrayList; | |
import java.util.Collections; | |
import java.util.Iterator; | |
import java.util.List; | |
public class Riding implements RidingInterface { | |
private String ridingName; | |
private List<CandidateInterface> candidates; | |
public Riding(String inRidingName) { |
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
<?php | |
/** | |
* Convert color from hex in XXXXXX (eg. FFFFFF, 000000, FF0000) to array(R, G, B) | |
* of integers (0-255). | |
* | |
* name: rgb2array | |
* author: Yetty | |
* @param $color hex in XXXXXX (eg. FFFFFF, 000000, FF0000) | |
* @return string; array(R, G, B) of integers (0-255) |
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
<?php | |
/** | |
* Convert color from hex in XXXXXX (eg. FFFFFF, 000000, FF0000) to array(R, G, B) | |
* of integers (0-255). | |
* | |
* name: rgb2array | |
* author: Yetty | |
* @param $color hex in XXXXXX (eg. FFFFFF, 000000, FF0000) | |
* @return string; array(R, G, B) of integers (0-255) |
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
<?php | |
/** | |
* Convert color from hex in XXXXXX (eg. FFFFFF, 000000, FF0000) to array(R, G, B) | |
* of integers (0-255). | |
* | |
* name: rgb2array | |
* author: Yetty | |
* @param $color hex in XXXXXX (eg. FFFFFF, 000000, FF0000) | |
* @return string; array(R, G, B) of integers (0-255) |
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
public class AlternateHockeyPlayerComparer{ | |
int compare(HockeyPlayer a, HockeyPlayer b){ | |
String aLastName = a.getLastName(); | |
String bLastName = b.getLastName(); | |
int difference = a.lastName.compareTo(b.lastName); | |
if(difference != 0){ | |
return difference; | |
} |
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
# Author: Andre Lashley | |
# Date: February 21, 2012 | |
# Description: Get user's information, display it and log it to a text file | |
def display_user_info(): | |
# get the users name | |
name = raw_input("Hello there, what's your name? ") | |
# get the users age |
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
<?php | |
/* | |
Lab 7 | |
circle.php | |
Andre Lashley (andre.lashley@gmail.com) | |
February 20, 2012 | |
4 hours estimated completion time | |
4 hours actual completion time | |
This program draws 6 different shapes. | |
Visit http://deepblue.cs.camosun.bc.ca/~cst020/comp170/lab7/main.html to use it. |
OlderNewer