Skip to content

Commit 10014f4

Browse files
author
Adria Vieira
committed
sort-objects task translated
1 parent 49cc586 commit 10014f4

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

1-js/05-data-types/05-array-methods/8-sort-objects/solution.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ let arr = [ pete, john, mary ];
1111

1212
sortByAge(arr);
1313

14-
// now sorted is: [john, mary, pete]
14+
// agora a ordenação: [john, mary, pete]
1515
alert(arr[0].name); // John
1616
alert(arr[1].name); // Mary
1717
alert(arr[2].name); // Pete

1-js/05-data-types/05-array-methods/8-sort-objects/task.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ importance: 5
44

55
# Sort users by age
66

7-
Write the function `sortByAge(users)` that gets an array of objects with the `age` property and sorts them by `age`.
7+
Escreva a função `sortByAge(users)` que recebe um array de objetos com a propriedade `age` e o ordene por `age`.
88

9-
For instance:
9+
Por exemplo:
1010

1111
```js no-beautify
1212
let john = { name: "John", age: 25 };
@@ -17,7 +17,7 @@ let arr = [ pete, john, mary ];
1717

1818
sortByAge(arr);
1919

20-
// now: [john, mary, pete]
20+
// agora: [john, mary, pete]
2121
alert(arr[0].name); // John
2222
alert(arr[1].name); // Mary
2323
alert(arr[2].name); // Pete

0 commit comments

Comments
 (0)