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 Point | |
{ | |
public int X { get; set; } | |
public int Y { get; set; } | |
public Point(int x, int y) | |
{ | |
X = x; | |
Y = y; | |
} |
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
Point{} |
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 static bool operator > (Point a, Point b) | |
{ | |
return a.X > b.X; | |
} | |
public static bool operator < (Point a, Point b) | |
{ | |
return a.X < b.X; | |
} |
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
constructor(props) { | |
super(props); | |
this.state = { | |
faceValue: 0, | |
face: "⚀", | |
rollCount: 1, | |
isRolling: false, | |
}; | |
this.DiceRoll = this.DiceRoll.bind(this); | |
this.HandleDiceThrow = this.HandleDiceThrow.bind(this); |
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
{ | |
StreamReader sr = new StreamReader(filename); | |
try | |
{ | |
String text = sr.ReadToEnd(); | |
return text; | |
} | |
finally | |
{ | |
if (sr != null) |
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
[].reduce(function(a, b){ | |
return a + b; | |
}); |