Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
ai
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
ai
Commits
c7104e04
Commit
c7104e04
authored
Jun 16, 2022
by
Ahmad Nemati
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
git pull
parent
74e708f5
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
10 deletions
+5
-10
torobche.js
torobche.js
+5
-10
No files found.
torobche.js
View file @
c7104e04
...
@@ -57,17 +57,12 @@ let index=arrNew[0].index
...
@@ -57,17 +57,12 @@ let index=arrNew[0].index
arrNew
=
[]
arrNew
=
[]
for
(
let
i
=
index
;
i
<
index
+
1
;
i
++
)
{
for
(
let
i
=
index
;
i
<
index
+
1
;
i
++
)
{
let
sums
=
0
let
sums
=
0
for
(
let
j
=
i
+
1
;
j
<
arr
.
length
;
j
++
)
{
sums
=
sums
+
parseFloat
(
arr
[
i
].
profit
)
sums
=
sums
+
parseFloat
(
arr
[
j
].
profit
)
// if (arrNew.length ===0)
// if (arrNew.length ===0)
// arrNew.push({sum: sums, index: i,date:arr[j].date})
// arrNew.push({sum: sums, index: i,date:arr[j].date})
// else if (arrNew[arrNew.length-1].sum > sums)
// else if (arrNew[arrNew.length-1].sum > sums)
arrNew
.
push
({
sum
:
sums
,
index
:
i
,
date
:
arr
[
j
].
date
})
arrNew
.
push
({
sum
:
sums
,
index
:
i
,
date
:
arr
[
i
].
date
})
}
}
}
let
t
=
''
let
t
=
''
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment