Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
V
vebinar_11
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
Нұрасыл Қайратұлы
vebinar_11
Commits
d87ca1e6
Commit
d87ca1e6
authored
Dec 06, 2023
by
Nurasyl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add total arr val
parent
70b4ab9f
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
6 deletions
+23
-6
index.js
JS/index.js
+23
-6
No files found.
JS/index.js
View file @
d87ca1e6
...
@@ -50,11 +50,28 @@
...
@@ -50,11 +50,28 @@
// showResult(groupArr);
// showResult(groupArr);
const
groupArr
=
[
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
];
//
const groupArr = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
let
total
=
0
;
//
let total = 0;
for
(
let
i
=
0
;
i
<
groupArr
.
length
;
i
++
)
{
// for(let i = 0; i < groupArr.length; i++) {
total
+=
groupArr
[
i
];
// total += groupArr[i];
};
// };
// console.log(total / groupArr.length);
// function exampel(a, b) {
// let c = a + b;
// return c;
// };
// let f = exampel(10, 5);
// console.log(f);
// function getAnswer() { return prompt("Ведите что либо:") };
console
.
log
(
total
/
groupArr
.
length
);
// console.log(getAnswer());
\ No newline at end of file
\ No newline at end of file
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