← Winnitude! Search  ·  Reader Mode (2491 ms)
Links: Stay in Reader Retro Site Converter Retro Mode: OFF Original Page ↗
GITHUB · 124 LINKS

Conditional branching: if, '?' by jonnathan-ls · Pull Request #246 · javascript-tutorial/pt.javascript.info

Repository navigation

Conditional branching: if, '?' - #246


Merged
nazarepiedady merged 6 commits into javascript-tutorial:master from jonnathan-ls:feature/steps-ifelse Dec 23, 2023
Merged

Conditional branching: if, '?' #246 nazarepiedady merged 6 commits into javascript-tutorial:master from jonnathan-ls:feature/steps-ifelse

Conversation

jonnathan-ls commented Jun 29, 2022 · edited Loading



Copy link Copy Markdown
Contributor

Conditional branching: if, '?'

📝 Goal

Article translation

☑ What was done?

  • Translation of the article
  • Translation of the exercises
  • Translation of the SVG image
feat(steps): translates the article about conditional branching 2c71b37 javascript-translate-bot added the review needed label Jun 29, 2022 javascript-translate-bot requested a review from a team June 29, 2022 03:31 jonnathan-ls changed the title WIP: Conditional branching: if, '?' WIP Conditional branching: if, '?' Jun 29, 2022

jonnathan-ls commented Jun 29, 2022



Copy link Copy Markdown
Contributor

Author

🚧 work in progress

jonnathan-ls added 2 commits July 7, 2022 00:01 Merge branch 'master' of https://github.com/jonnathan-ls/pt.javascrip... ad77bb6
...t.info into feature/steps-ifelse
feat(first-steps): translates the images of article about conditional... 6cad86f
... branching
jonnathan-ls changed the title WIP Conditional branching: if, '?' Conditional branching: if, '?' Jul 7, 2022

jonnathan-ls commented Jul 7, 2022



Copy link Copy Markdown
Contributor

Author

✅ Ready for review

jonnathan-ls mentioned this pull request Aug 13, 2022 Portuguese Translation Progress #1 Open odsantos requested changes Dec 6, 2022
View reviewed changes

odsantos left a comment



Copy link Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hi, Please fell free to tell where you disagree. Thanks, Osvaldo.

Comment thread 1-js/02-first-steps/10-ifelse/1-if-zero-string/task.md
Outdated
---

# if (a string with zero)
# f (uma " string " com zero)
Comment thread 1-js/02-first-steps/10-ifelse/2-check-standard/task.md
Outdated
Usando a construção `if..else` , escreva o código que pergunta : ' Qual é o nome "oficial" do JavaScript?'

If the visitor enters "ECMAScript", then output "Right !", otherwise -- output : " You don't know ? ECMAScript!"
Se o visitante digitar "ECMAScript", então chame a função alerta passando como valor: "correto !", caso contrário -- registre a seguinte mensagem : " Você não sabe ? ECMAScript!"
Comment thread 1-js/02-first-steps/10-ifelse/3-sign/task.md
Outdated
---

# Show the sign
# Mostra o sinal
Comment thread 1-js/02-first-steps/10-ifelse/3-sign/task.md
Outdated
- `0`, if equals zero.
- `1`, se o valor for maior que zero,
- `-1`, se menor que zero,
- `0`, se for igual a zero.
Comment thread 1-js/02-first-steps/10-ifelse/article.md
# Ramificação condicional : if, '?'

Sometimes, we need to perform different actions based on different conditions .
Às vezes, precisamos realizar ações diferentes com base em condições diferentes .
Comment thread 1-js/02-first-steps/10-ifelse/article.md
Outdated
The so-called "conditional" or "question mark" operator lets us do that in a shorter and simpler way.
O chamado operador "condicional" ou "ponto de interrogação" nos permite fazer isso de uma forma curta e simples.

O operador é representado por um ponto de interrogação `?`. Às vezes referênciado como "ternário", porque o operador possui três operandos. Na verdade, é o único operador em JavaScript que possui tantos. Na verdade, é o único operador em JavaScript que possui tantas possibilidades de operandos.
Comment thread 1-js/02-first-steps/10-ifelse/article.md
Outdated

```js run no-beautify
let company = prompt(' Which company created JavaScript?', '');
let company = prompt(' Qual empresa criou o JavaScript?', '');
Comment thread 1-js/02-first-steps/10-ifelse/article.md
Outdated
** Não é recomendado usar o operador de ponto de interrogação dessa maneira .**

The notation is shorter than the equivalent `if` statement, which appeals to some programmers. But it is less readable .
A notação é mais curta do que a instrução `if` equivalente, que atrai alguns programadores. Mas é menos legível .
Comment thread 1-js/02-first-steps/10-ifelse/article.md
Outdated

```js run no-beautify
let company = prompt(' Which company created JavaScript?', '');
let company = prompt(' Qual empresa criou o JavaScript?', '');
Comment thread 1-js/02-first-steps/10-ifelse/article.md
Nossos olhos escaneiam o código verticalmente. Blocos de código que abrangem várias linhas são mais fáceis de entender do que um conjunto de instruções longo e horizontal .

The purpose of the question mark operator `?` is to return one value or another depending on its condition. Please use it for exactly that . Use `if` when you need to execute different branches of code .
O objetivo do operador de ponto de interrogação `?` é retornar um valor ou outro dependendo de sua condição. Por favor, use -o exatamente para isso . Use `if` quando precisar executar diferentes ramificações de código .
javascript-translate-bot removed the review needed label Dec 6, 2022

javascript-translate-bot commented Dec 6, 2022



Copy link Copy Markdown

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

javascript-translate-bot added the changes requested label Dec 6, 2022

odsantos commented Dec 16, 2022



Copy link Copy Markdown
Contributor

Hi @jonnathan-ls ,

I updated to the English version.
As part of the pending tasks could you also resolve the conflicts?

Thanks,
Osvaldo.

jonnathan-ls added 2 commits March 26, 2023 19:54 Merge branch 'master' of https://github.com/jonnathan-ls/pt.javascrip... 203e90c
...t.info into feature/steps-ifelse
refactor: corrige sugestões conforme code review #pullrequestreview-1... f38a7d5
...207296036

Code Review: javascript-tutorial#246 (review)

jonnathan-ls commented Mar 26, 2023



Copy link Copy Markdown
Contributor

Author

Hi @jonnathan-ls ,

I updated to the English version. As part of the pending tasks could you also resolve the conflicts?

Thanks, Osvaldo.

@odsantos conflitos resolvidos.

jonnathan-ls commented Mar 26, 2023 · edited Loading



Copy link Copy Markdown
Contributor

Author

Hi, Please fell free to tell where you disagree. Thanks, Osvaldo.

@odsantos
Correções realizadas.

Apenas algumas sugestões relacionadas a preposição "de", pois entendo que fica um pouco estranho para o leitor.

jonnathan-ls commented Apr 2, 2023



Copy link Copy Markdown
Contributor

Author

/done

javascript-translate-bot added review needed and removed changes requested labels Apr 2, 2023 javascript-translate-bot requested a review from a team April 2, 2023 20:35

nazarepiedady commented Dec 15, 2023



Copy link Copy Markdown
Member

@jonnathan-ls have you time to update this translation and correct its conflicts?

jonnathan-ls commented Dec 15, 2023



Copy link Copy Markdown
Contributor

Author

@jonnathan-ls have you time to update this translation and correct its conflicts?

Sure, I'll do it on the weekend

nazarepiedady commented Dec 15, 2023



Copy link Copy Markdown
Member

@jonnathan-ls I also recommend looking at all your pull requests to see what more needs to be done to let the pull request fine be applied.

Merge branch 'master' of https://github.com/javascript-tutorial/pt.ja... 2f76d90
...vascript.info into feature/steps-ifelse

jonnathan-ls commented Dec 16, 2023



Copy link Copy Markdown
Contributor

Author

Conflicts resolved @nazarepiedady

@odsantos awaiting analysis of the corrections I made according to your review

nazarepiedady commented Dec 23, 2023



Copy link Copy Markdown
Member

@jonnathan-ls Are all reviews requested by @odsantos resolved?

jonnathan-ls commented Dec 23, 2023



Copy link Copy Markdown
Contributor

Author

Are all reviews requested by @odsantos resolved?

Yes, i am waiting his to review again

jonnathan-ls commented Dec 23, 2023



Copy link Copy Markdown
Contributor

Author

/done

nazarepiedady merged commit a1de0f9 into javascript-tutorial : master Dec 23, 2023

javascript-translate-bot commented Dec 23, 2023



Copy link Copy Markdown

Thank you 💖 I updated the Progress Issue #1 🎉 🎉 🎉

Sign up for free to join this conversation on GitHub . Already have an account? Sign in to comment

Labels

review needed

4 participants