mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-24 05:20:04 +08:00
14 lines
272 B
TypeScript
14 lines
272 B
TypeScript
module Geometry {
|
|
export class Square {
|
|
constructor(public sideLength: number = 0) {
|
|
}
|
|
area() {
|
|
return Math.pow(this.sideLength, 2);
|
|
}
|
|
}
|
|
}
|
|
|
|
class Tuple<T1, T2> {
|
|
constructor(public item1: T1, public item2: T2) { }
|
|
}
|