Posts by Lucas • 41 points
5 posts
-
0
votes1
answer53
viewsQ: Potentiation with array
I thought of the following code to calculate the square of each value in array: double []vetor = {1,2,3,4,5,6,7,8,10}; double result = 0; foreach(double posicao in vetor){ result = Math.Pow(posicao,…
-
1
votes1
answer184
viewsQ: Show array in reverse order
I thought of this code to show the reverse order. It worked, but I was wondering if there is another possible way. function inversa(...ray){ console.log(`Os elementos do array são: ${ray.join(',…
javascriptasked Lucas 41 -
-1
votes1
answer297
viewsQ: Array with negative numbers javascript
I am trying to do an exercise where I have that shows the values of 5 numbers that can be positive or negative but only the negative numbers of the array will be shown and also inform how many…
javascriptasked Lucas 41 -
0
votes2
answers161
views -
1
votes2
answers34
viewsQ: Reveal the Boolean value
I have a function that checks whether the numbers passed nor arguments are equal if they are not wanted to show the highest number. But I don’t know how to show the greatest.... function…
javascriptasked Lucas 41