translating

This commit is contained in:
Ilya Kantor 2016-03-21 10:16:55 +03:00
parent 2b874a73be
commit 928cd2731b
165 changed files with 2046 additions and 2967 deletions

View file

@ -2,17 +2,10 @@ importance: 3
---
# Получить случайное значение из массива
# A random array value
Напишите код для вывода `alert` случайного значения из массива:
Write the code to `alert` a random value from the array:
```js
var arr = ["Яблоко", "Апельсин", "Груша", "Лимон"];
let arr = ["Apple", "Orange", "Pear", "Lemon"];
```
P.S. Код для генерации случайного целого от `min` to `max` включительно:
```js
var rand = min + Math.floor(Math.random() * (max + 1 - min));
```