diff options
author | Marcin Junczys-Dowmunt <junczys@amu.edu.pl> | 2016-05-04 01:18:12 +0300 |
---|---|---|
committer | Marcin Junczys-Dowmunt <junczys@amu.edu.pl> | 2016-05-04 01:18:12 +0300 |
commit | d19f1f610f840c02f1e71512ce3ec5a2fe1f579b (patch) | |
tree | 91d118e85e1ffd8bf613e1cc3fd43666024b614a /src | |
parent | 437863be388925cdbc0ab9bbb020af6230d9634e (diff) |
in loop
Diffstat (limited to 'src')
-rw-r--r-- | src/test.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/test.cpp b/src/test.cpp index 147f9015..e919925d 100644 --- a/src/test.cpp +++ b/src/test.cpp @@ -16,8 +16,11 @@ int main(int argc, char** argv) { Var y = 0.0; for(int i = 0; i < max; i++) { Var xi = i; - y = y + x0 + log(x2) + x1 + xi; - x.push_back(xi); + y = y + x0 + log(x2) + x1; + for(int j = 0; j < i; ++i) { + y = y + xi; + x.push_back(xi); + } } |