summaryrefslogtreecommitdiff
path: root/ms/ms.go
diff options
context:
space:
mode:
authorWill Hawkins <[email protected]>2022-11-07 10:11:09 -0500
committerWill Hawkins <[email protected]>2022-11-07 10:11:26 -0500
commitf7d143bcf8703c41a39d9b8e7896b6e7468d6fd7 (patch)
treec2ca0999d4f693fa3900ecdb280a5fae3cccbd1b /ms/ms.go
parentea39f3e0ddd0b35bf649477f628fabbc0c1ca424 (diff)
Add Size() method for MathmematicalSeries.
Diffstat (limited to 'ms/ms.go')
-rw-r--r--ms/ms.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/ms/ms.go b/ms/ms.go
index da2d201..fc0fe95 100644
--- a/ms/ms.go
+++ b/ms/ms.go
@@ -137,3 +137,7 @@ func (ma *MathematicalSeries[T]) IsNormallyDistributed() bool {
func (ma *MathematicalSeries[T]) Values() []T {
return ma.elements
}
+
+func (ma *MathematicalSeries[T]) Size() int {
+ return len(ma.elements)
+}