Skip to content

Add files via upload #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Add files via upload #8

wants to merge 1 commit into from

Conversation

codebasecodebase
Copy link
Owner

No description provided.

<body>
<script>

class Point {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Создавать класс ради создания функции - лишняя затея. Коли уж делаете класс с методом, то используйте в этом методе контекст



getRandomNumber();
function getRandomNumber(){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Функция должна принимать число и называться в соответствии с тем, что делает, а также возвращать результат, а не выводить его внутри


for (let i=0; i < chislo; i++) {
massive.push({
adres_home: "Zvezdi 22",

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

camelCase




var amount = massive.reduce ((total, person) => {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

const/let




var amount = massive.reduce ((total, person) => {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Должно быть оформлено в виде методов объекта-дома


//console.log(arr33);

arr333 = [];

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Наименование переменных не отражает хранимое


console.table(massive);

array = massive.reduceRight(function(sum, elem) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let/const здесь и далее

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants