aboutsummaryrefslogtreecommitdiffstats
path: root/math2373/lab5/sum_of_nn.m
diff options
context:
space:
mode:
authorMatthew Strapp <msattr@gmail.com>2019-10-14 10:10:14 -0500
committerMatthew Strapp <msattr@gmail.com>2019-10-14 10:10:14 -0500
commitc944368c607add79fc3ea404629f717b42a834ce (patch)
tree78ae81ea0fc0d54ab532e8e0e5eaad2cc931c6b9 /math2373/lab5/sum_of_nn.m
parentMerge branch 'master' of github.com:RosstheRoss/TestingFun (diff)
downloadhomework-c944368c607add79fc3ea404629f717b42a834ce.tar
homework-c944368c607add79fc3ea404629f717b42a834ce.tar.gz
homework-c944368c607add79fc3ea404629f717b42a834ce.tar.bz2
homework-c944368c607add79fc3ea404629f717b42a834ce.tar.lz
homework-c944368c607add79fc3ea404629f717b42a834ce.tar.xz
homework-c944368c607add79fc3ea404629f717b42a834ce.tar.zst
homework-c944368c607add79fc3ea404629f717b42a834ce.zip
fix the oopsies
Diffstat (limited to 'math2373/lab5/sum_of_nn.m')
-rw-r--r--math2373/lab5/sum_of_nn.m4
1 files changed, 2 insertions, 2 deletions
diff --git a/math2373/lab5/sum_of_nn.m b/math2373/lab5/sum_of_nn.m
index ea36db5..dd191b7 100644
--- a/math2373/lab5/sum_of_nn.m
+++ b/math2373/lab5/sum_of_nn.m
@@ -1,4 +1,4 @@
-y(1)=0;
+y=0;
for n=1:N
- y(n+1)=y(n)+1/(n^n);
+ y=y+1/(n^n);
end \ No newline at end of file