diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 00000000..81b3a260 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,32 @@ +--- +name: Bug report +about: Create a report to help us improve +title: '' +labels: '' +assignees: '' + +--- + +**Describe the bug** +A clear and concise description of what the bug is. + +**To Reproduce** +Steps to reproduce the behavior: +1. Go to '...' +2. Click on '....' +3. Scroll down to '....' +4. See error + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Execution environment (please complete the following information):** + - OS: [e.g. iOS] + - Version [e.g. 2.7.2] + - Node Version [e.g. v12.10.0] + +**Additional context** +Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/new-challenge-proposal.md b/.github/ISSUE_TEMPLATE/new-challenge-proposal.md new file mode 100644 index 00000000..645b99bf --- /dev/null +++ b/.github/ISSUE_TEMPLATE/new-challenge-proposal.md @@ -0,0 +1,38 @@ +--- +name: New Challenge Proposal +about: Propose a new challenge for learning JavaScript +title: '' +labels: '' +assignees: '' + +--- + +**Title** + + + +**Goal** + + +** Problem ** + + + +TODO diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml new file mode 100644 index 00000000..1aae01e5 --- /dev/null +++ b/.github/workflows/node.js.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean install of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions + +name: Node.js CI + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [20.x, 19.x, 18.x, 16.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run build --if-present + - run: npm test diff --git a/.gitignore b/.gitignore index 9daa8247..b666e34b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .DS_Store node_modules +.settings diff --git a/.workshopper-test.config.js b/.workshopper-test.config.js new file mode 100644 index 00000000..4bc2865a --- /dev/null +++ b/.workshopper-test.config.js @@ -0,0 +1,5 @@ +module.exports = { + exercisesFolder: 'solutions', + testFileRegex: 'index.js', + spaceChar: '-' +} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..da4d04d0 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,23 @@ +# Contributing + +Code contributions are welcome and highly encouraged! For instructions on and help with creating a great pull request, please read the [workshopper contributing document](https://github.com/workshopper/org/blob/master/CONTRIBUTING.md). + +If you have questions about contributing, please create an issue. + +## Lead Maintainers + +The role of lead maintainers is to triage and categorize issues, answer questions about contributing to the repository, review and give feedback on PRs, and maintain the quality of a workshopper's codebase and repository. + +**Current Lead Maintainers** +- Seth Vincent [@sethvincent](https://github.com/sethvincent) +- Adam Brady [@SomeoneWeird](https://github.com/SomeoneWeird) +- Anshul [@AnshulMalik](https://github.com/AnshulMalik) +- Martin Splitt [@AVGP](https://github.com/AVGP) +- Seth [@itzsaga](https://github.com/itzsaga) +- Lawal Sauban [@sauban](https://github.com/sauban) + +### Volunteer + +Submitting many PRs? Please volunteer to lead this repository! Lead maintainers are selected in the philosophy of [Open Open Source](http://openopensource.org/): + +> Individuals making significant and valuable contributions are given commit-access to the project to contribute as they see fit. diff --git a/LOCALIZING.md b/LOCALIZING.md new file mode 100644 index 00000000..c7e15e61 --- /dev/null +++ b/LOCALIZING.md @@ -0,0 +1,96 @@ +# Localization HOWTO + +In computing, localization is the process of adapting software to different languages, regional differences, cultural preferences, and technical requirements of a target audience. + +This guide explains how to contribute a new localization to this workshopper. If you are an international user and would like to bring Nodeschool workshops to a broader audience, please consider contributing a localization! It is simple, fun, and enables more people to learn and practice. + +## Menu + +The menu of the workshopper greets the user with a list of problem names. The strings for these names are contained in the top level `menu.json` file. Translations of problem names should be placed in a JSON file inside the `i18n` folder named with the language code, e.g. `es.json`. Use an existing translation file as reference, ensuring it's up to date with the contents of `menu.json`. + +```json +{ + "exercise": { + "INTRODUCTION": "INTRODUCCIÓN" + , "FIRST PROBLEM": "PRIMER PROBLEMA" + , "SECOND PROBLEM": "SEGUNDO PROBLEMA" + , "LAST PROBLEM": "ÚLTIMO PROBLEMA" + } +} +``` + +## Footer + +Workshoppers usually display a footer beneath the problem description, providing the user with help or additional information to make their way through. The footer is a [Markdown](https://en.wikipedia.org/wiki/Markdown) file located inside the `i18n/footer` directory, named after the language code, e.g. `ja.md`. + +In order to add a localized footer for Spanish, create a `es.md` file inside the `i18n/footer` directory, containing the translation of the English file `en.md`. + +## Troubleshooting tips + +Similarly, workshoppers display troubleshooting tips when the user submits a wrong solution for the exercise. Tips are contained in a [Markdown](https://en.wikipedia.org/wiki/Markdown) file located inside the `i18n` directory, named after the language code, e.g. `troubleshooting-ja.md`. + +In order to add translated troubleshooting tips for Spanish, create a `troubleshooting_es.md` file inside the `i18n` directory, containing the translation of the English file `troubleshooting.md`. + +## Problems and solutions + +The text of each problem and the message printed when the user solves it can be localized by adding [Markdown](https://en.wikipedia.org/wiki/Markdown) files with a well defined name inside the problem directory, which is a subdirectory of the `problems` directory. Consider this structure: + +``` ++-- problems +| +-- problem-1 +| | +-- index.js +| | +-- problem.md +| | +-- problem_ja.md +| | +-- problem_zh-cn.md +| | +-- solution.md +| | +-- solution_ja.md +| | `-- solution_zh-cn.md +| +-- problem-2 +| | +-- index.js +| | +-- problem.md +| | +-- problem_ja.md +| | +-- problem_zh-cn.md +| | +-- solution.md +| | +-- solution_ja.md +| | `-- solution_zh-cn.md +: : +``` + +As you can see, translation file names are in the format `problem_xx.md` and `solution_xx.md` where the `xx` suffix is the language code. + +In order to add the Spanish localization, we must add new `problem_es.md` and `solution_es.md` files inside each problem directory as follows: + +``` ++-- problems +| +-- problem-1 +| | +-- index.js +| | +-- problem.md +| | +-- problem_es.md +| | +-- problem_ja.md +| | +-- problem_zh-cn.md +| | +-- solution.md +| | +-- solution_es.md +| | +-- solution_ja.md +| | `-- solution_zh-cn.md +| +-- problem-2 +| | +-- index.js +| | +-- problem.md +| | +-- problem_es.md +| | +-- problem_ja.md +| | +-- problem_zh-cn.md +| | +-- solution.md +| | +-- solution_es.md +| | +-- solution_ja.md +| | `-- solution_zh-cn.md +: : +``` + +This is probably the most complex and time consuming task of localizing a workshopper, as problems often interleave paragraphs of text, code snippets and suggestions. + +Please remember to use welcoming and inclusive language. The [Contributor Covenant](http://contributor-covenant.org/) offers guidelines if you're unsure. + +## Testing + +In order to test a translation, launch the workshopper and choose the desired language selecting the menu option `CHOOSE LANGUAGE`. If you don't see the language you contributed listed in the options, chances are you didn't save your updates to the list of languages in the `index.js`. + +Once you're satisfied with the results, commit your changes and push to your repo, then submit a PR to the main workshopper repo! diff --git a/README.md b/README.md index 2fb0a666..c9c8fd3a 100644 --- a/README.md +++ b/README.md @@ -5,27 +5,26 @@ > _Looking for more interactive tutorials like this? Go to [nodeschool.io](http://nodeschool.io)._ ## Get help -Having issues with javascripting? Get help troubleshooting in the [nodeschool discussions repo](http://github.com/nodeschool/discussions), or on gitter: +Having issues with javascripting? Get help troubleshooting in the [nodeschool discussions repo](https://github.com/nodeschool/discussions), +on [gitter](https://gitter.im/nodeschool/discussions) or in [repository issues](https://github.com/workshopper/javascripting/issues) -[![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/nodeschool/discussions?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) +Also, take a look into our [troubleshooting documentation](https://github.com/workshopper/javascripting/blob/master/TROUBLESHOOTING.md) ## Install Node.js Make sure Node.js is installed on your computer. -Install it from [nodejs.org/download](http://nodejs.org/download) +Install it from [nodejs.org](https://nodejs.org/) ### Install `javascripting` with `npm` Open your terminal and run this command: ``` -npm install --global javascripting +npm install -g javascripting ``` -The `--global` option installs this module globally so that you can run it as a command in your terminal. - -> Having issues with installation? If you get an EACCESS error you can prefix the command with `sudo`, but also take a look at this npm documentation for fixing permissions so that you don't have to use `sudo`: https://docs.npmjs.com/getting-started/fixing-npm-permissions +The `-g` option installs this module globally so that you can run it as a command in your terminal. ## Run the workshop @@ -55,18 +54,13 @@ You can use any editor you like. ## Need help with an exercise? -Open an issue in the nodeschool/discussions repo: https://github.com/nodeschool/discussions +Open an issue in the [nodeschool/discussions repo](https://github.com/nodeschool/discussions) Include the name `javascripting` and the name of the challenge you're working on in the title of the issue. -## TODOS: - -Add these challenges: +## Get Involved -- "OBJECT KEYS" -- "FUNCTION RETURN VALUES" -- "THIS" -- "SCOPE" +Code contributions welcome! Please check our [documentation on contributing](https://github.com/workshopper/javascripting/blob/master/CONTRIBUTING.md) to get started. ## License diff --git a/TROUBLESHOOTING.md b/TROUBLESHOOTING.md new file mode 100644 index 00000000..4b9d3500 --- /dev/null +++ b/TROUBLESHOOTING.md @@ -0,0 +1,17 @@ +# Troubleshooting + +### `EACCESS` error + +If you get an `EACCESS` error, the simplest way to fix this is to rerun the command, in either of the following ways: + +- On unix shells, prefix the command with sudo +> `sudo npm install --global javascripting` + +- On Windows and if using either PowerShell or CMD, ensure you open the shell with administrator privilege. + +You can also fix the permissions so that you don't have to use `sudo`. Take a look at this npm documentation: +https://docs.npmjs.com/getting-started/fixing-npm-permissions + +### `EEXIST` error + +Make sure you are using an active version of Node.js. Active versions can be found [here](https://nodejs.org/en/about/releases/). diff --git a/bin/javascripting b/bin/javascripting new file mode 100755 index 00000000..6a9d2075 --- /dev/null +++ b/bin/javascripting @@ -0,0 +1,3 @@ +#!/usr/bin/env node + +require('../index').execute(process.argv.slice(2)) \ No newline at end of file diff --git a/i18n/es.json b/i18n/es.json index 9b8e6d31..b14ec463 100644 --- a/i18n/es.json +++ b/i18n/es.json @@ -15,9 +15,10 @@ , "ACCESSING ARRAY VALUES": "ACCEDIENDO ARRAYS" , "LOOPING THROUGH ARRAYS": "RECORRIENDO ARRAYS" , "OBJECTS": "OBJETOS" - , "OBJECT PROPERTIES": "PROPIEDADES DE OBJECTOS" + , "OBJECT PROPERTIES": "PROPIEDADES DE OBJETOS" + , "OBJECT KEYS": "LLAVES/KEYS DE OBJETOS" , "FUNCTIONS": "FUNCIONES" , "FUNCTION ARGUMENTS": "ARGUMENTOS DE FUNCIONES" , "SCOPE": "CONTEXTO" } -} \ No newline at end of file +} diff --git a/i18n/footer/en.md b/i18n/footer/en.md new file mode 100644 index 00000000..647a502d --- /dev/null +++ b/i18n/footer/en.md @@ -0,0 +1 @@ +__Need help?__ View the README for this workshop: https://github.com/workshopper/javascripting diff --git a/i18n/footer/es.md b/i18n/footer/es.md new file mode 100644 index 00000000..ec7e0c53 --- /dev/null +++ b/i18n/footer/es.md @@ -0,0 +1 @@ +__Necesitas ayuda?__ Vista el README de este workshop: https://github.com/workshopper/javascripting diff --git a/i18n/footer/fr.md b/i18n/footer/fr.md new file mode 100644 index 00000000..40a561be --- /dev/null +++ b/i18n/footer/fr.md @@ -0,0 +1 @@ +__Besoin d'aide ?__ Voir le README pour cet atelier: https://github.com/workshopper/javascripting diff --git a/i18n/footer/it.md b/i18n/footer/it.md new file mode 100644 index 00000000..bdf471f8 --- /dev/null +++ b/i18n/footer/it.md @@ -0,0 +1 @@ +__Serve aiuto?__ Leggi il README di questo workshop: https://github.com/workshopper/javascripting diff --git a/i18n/footer/ja.md b/i18n/footer/ja.md new file mode 100644 index 00000000..f3f0b833 --- /dev/null +++ b/i18n/footer/ja.md @@ -0,0 +1 @@ +__ヘルプが必要ですか??__ このワークショップのREADMEを読んでください。: https://github.com/ledsun/javascripting diff --git a/i18n/footer/ko.md b/i18n/footer/ko.md new file mode 100644 index 00000000..721fae18 --- /dev/null +++ b/i18n/footer/ko.md @@ -0,0 +1 @@ +__도움이 필요하신가요?__ 이 워크숍의 README를 확인하세요: https://github.com/workshopper/javascripting diff --git a/i18n/footer/nb-no.md b/i18n/footer/nb-no.md new file mode 100644 index 00000000..ae36f84f --- /dev/null +++ b/i18n/footer/nb-no.md @@ -0,0 +1 @@ +__Trenger du hjelp?__ Se README-filen for denne workshopen: https://github.com/workshopper/javascripting diff --git a/i18n/footer/nl.md b/i18n/footer/nl.md new file mode 100644 index 00000000..0bb22037 --- /dev/null +++ b/i18n/footer/nl.md @@ -0,0 +1 @@ +__Hulp nodig? __ Lees de README voor deze workshop: https://github.com/workshopper/javascripting diff --git a/i18n/footer/pt-br.md b/i18n/footer/pt-br.md new file mode 100644 index 00000000..40b78913 --- /dev/null +++ b/i18n/footer/pt-br.md @@ -0,0 +1 @@ +__Precisa de ajuda?__ Leia o README deste workshop: https://github.com/workshopper/javascripting diff --git a/i18n/footer/ru.md b/i18n/footer/ru.md new file mode 100644 index 00000000..3cba98f1 --- /dev/null +++ b/i18n/footer/ru.md @@ -0,0 +1 @@ +__Требуется помощь?__ Перечитайте README данного воркшопа: https://github.com/workshopper/javascripting diff --git a/i18n/footer/uk.md b/i18n/footer/uk.md new file mode 100644 index 00000000..2d230242 --- /dev/null +++ b/i18n/footer/uk.md @@ -0,0 +1 @@ +__Потрібна допомога?__ Перегляньте README цього воркшопу: https://github.com/workshopper/javascripting diff --git a/i18n/footer/zh-cn.md b/i18n/footer/zh-cn.md new file mode 100644 index 00000000..94d6b6b6 --- /dev/null +++ b/i18n/footer/zh-cn.md @@ -0,0 +1 @@ +__需要帮助?__ 查看本教程的 README 文件:https://github.com/workshopper/javascripting diff --git a/i18n/footer/zh-tw.md b/i18n/footer/zh-tw.md new file mode 100644 index 00000000..985e0314 --- /dev/null +++ b/i18n/footer/zh-tw.md @@ -0,0 +1 @@ +__需要幫助?__ 查看本教學的 README 文件:https://github.com/workshopper/javascripting diff --git a/i18n/fr.json b/i18n/fr.json new file mode 100644 index 00000000..7b73febe --- /dev/null +++ b/i18n/fr.json @@ -0,0 +1,24 @@ +{ + "exercise": { + "INTRODUCTION": "INTRODUCTION" + , "VARIABLES": "VARIABLES" + , "STRINGS": "CHAÎNES DE CARACTÈRES" + , "STRING LENGTH": "LONGUEUR DE CHAÎNES DE CARACTÈRES" + , "REVISING STRINGS": "MODIFIER UNE CHAÎNE DE CARACTÈRES" + , "NUMBERS": "NOMBRES" + , "ROUNDING NUMBERS": "ARRONDIS" + , "NUMBER TO STRING": "NOMBRES EN CHAÎNES DE CARACTÈRES" + , "IF STATEMENT": "OPÉRATEUR IF" + , "FOR LOOP": "BOUCLE FOR" + , "ARRAYS": "TABLEAUX" + , "ARRAY FILTERING": "FILTRAGE DE TABLEAUX" + , "ACCESSING ARRAY VALUES": "ACCÉDER AUX VALEURS D'UN TABLEAU" + , "LOOPING THROUGH ARRAYS": "ITÉRER SUR UN TABLEAU" + , "OBJECTS": "OBJETS" + , "OBJECT PROPERTIES": "PROPRIÉTÉS D'OBJETS" + , "OBJECT KEYS": "CLÉS D'OBJETS" + , "FUNCTIONS": "FONCTIONS" + , "FUNCTION ARGUMENTS": "ARGUMENTS DE FONCTIONS" + , "SCOPE": "SCOPE" + } +} diff --git a/i18n/it.json b/i18n/it.json new file mode 100644 index 00000000..b3582590 --- /dev/null +++ b/i18n/it.json @@ -0,0 +1,24 @@ +{ + "exercise": { + "INTRODUCTION": "INTRODUZIONE" + , "VARIABLES": "LE VARIABILI" + , "STRINGS": "LE STRINGHE" + , "STRING LENGTH": "LUNGHEZZA DI UNA STRINGA" + , "REVISING STRINGS": "MODIFICARE UNA STRINGA" + , "NUMBERS": "I NUMERI" + , "ROUNDING NUMBERS": "ARROTONDARE UN NUMERO" + , "NUMBER TO STRING": "DA NUMERO A STRINGA" + , "IF STATEMENT": "BLOCCO CONDIZIONALE IF" + , "FOR LOOP": "CICLO FOR" + , "ARRAYS": "GLI ARRAY" + , "ARRAY FILTERING": "FILTRARE UN ARRAY" + , "ACCESSING ARRAY VALUES": "ACCEDERE AD UN ARRAY" + , "LOOPING THROUGH ARRAYS": "PERCORRERE UN ARRAY" + , "OBJECTS": "GLI OGGETTI" + , "OBJECT PROPERTIES": "PROPRIETÀ DI UN OGGETTO" + , "OBJECT KEYS": "LE CHIAVI DI UN OGGETTO" + , "FUNCTIONS": "LE FUNZIONI" + , "FUNCTION ARGUMENTS": "ARGOMENTI DELLA FUNZIONE" + , "SCOPE": "LO SCOPE" + } +} diff --git a/i18n/nb-no.json b/i18n/nb-no.json new file mode 100644 index 00000000..97df3d1f --- /dev/null +++ b/i18n/nb-no.json @@ -0,0 +1,23 @@ +{ + "exercise": { + "INTRODUCTION": "INTRODUKSJON" + , "VARIABLES": "VARIABLER" + , "STRINGS": "STRINGER" + , "STRING LENGTH": "STRINGENS LENGDE" + , "REVISING STRINGS": "ENDRE STRINGER" + , "NUMBERS": "NUMMER" + , "ROUNDING NUMBERS": "AVRUNDE NUMMER" + , "NUMBER TO STRING": "NUMMER TIL STRING" + , "IF STATEMENT": "IF UTTRYKK" + , "FOR LOOP": "FOR LØKKEN" + , "ARRAYS": "ARRAYER" + , "ARRAY FILTERING": "FILTERING AV ARRAYER" + , "ACCESSING ARRAY VALUES": "BRUKE ARRAY VERDIER" + , "LOOPING THROUGH ARRAYS": "ITERERE GJENNOM ARRAYER" + , "OBJECTS": "OBJEKTER" + , "OBJECT PROPERTIES": "OBJEKTEGENSKAPER" + , "FUNCTIONS": "FUNKSJONER" + , "FUNCTION ARGUMENTS": "FUNKSJONSARGUMENTER" + , "SCOPE": "KONTEKST" + } +} diff --git a/i18n/nl.json b/i18n/nl.json new file mode 100755 index 00000000..074b0625 --- /dev/null +++ b/i18n/nl.json @@ -0,0 +1,24 @@ +{ + "exercise": { + "INTRODUCTION": "INTRODUCTIE" + , "VARIABLES": "VARIABELEN" + , "STRINGS": "STRINGS" + , "STRING LENGTH": "LENGTE VAN STRINGS" + , "REVISING STRINGS": "AANPASSEN VAN STRINGS" + , "NUMBERS": "NUMMERS" + , "ROUNDING NUMBERS": "NUMMERS AFRONDEN" + , "NUMBER TO STRING": "NUMMER NAAR STRING" + , "IF STATEMENT": "IF STATEMENT" + , "FOR LOOP": "FOR LOOP" + , "ARRAYS": "ARRAYS" + , "ARRAY FILTERING": "ARRAYS FILTEREN" + , "ACCESSING ARRAY VALUES": "ARRAY WAARDEN OPVRAGEN" + , "LOOPING THROUGH ARRAYS": "LOOPEN DOOR ARRAYS" + , "OBJECTS": "OBJECTEN" + , "OBJECT PROPERTIES": "OBJECT EIGENSCHAPPEN" + , "OBJECT KEYS": "OBJECT KEYS" + , "FUNCTIONS": "FUNCTIES" + , "FUNCTION ARGUMENTS": "FUNCTIE ARGUMENTEN" + , "SCOPE": "SCOPE" + } +} diff --git a/i18n/pt-br.json b/i18n/pt-br.json new file mode 100644 index 00000000..a1a08fd4 --- /dev/null +++ b/i18n/pt-br.json @@ -0,0 +1,24 @@ +{ + "exercise": { + "INTRODUCTION": "INTRODUÇÃO" + , "VARIABLES": "VARIÁVEIS" + , "STRINGS": "STRINGS" + , "STRING LENGTH": "TAMANHO DAS STRINGS" + , "REVISING STRINGS": "MODIFICANDO STRINGS" + , "NUMBERS": "NÚMEROS" + , "ROUNDING NUMBERS": "ARREDONDANDO NÚMEROS" + , "NUMBER TO STRING": "CONVERTENDO NÚMERO PARA STRING" + , "IF STATEMENT": "CONDICIONAL COM IF" + , "FOR LOOP": "FAZENDO LOOP COM FOR" + , "ARRAYS": "ARRAYS" + , "ARRAY FILTERING": "FILTRANDO ARRAYS" + , "ACCESSING ARRAY VALUES": "ACESSANDO VALORES DE UM ARRAY" + , "LOOPING THROUGH ARRAYS": "VARRENDO ARRAYS COM LOOP" + , "OBJECTS": "OBJETOS" + , "OBJECT PROPERTIES": "PROPRIEDADES DE OBJETOS" + , "OBJECT KEYS": "CHAVES DE OBJETOS" + , "FUNCTIONS": "FUNÇÕES" + , "FUNCTION ARGUMENTS": "ARGUMENTOS DE FUNÇÕES" + , "SCOPE": "ESCOPO" + } +} diff --git a/i18n/ru.json b/i18n/ru.json new file mode 100644 index 00000000..ac4b11a0 --- /dev/null +++ b/i18n/ru.json @@ -0,0 +1,24 @@ +{ + "exercise": { + "INTRODUCTION": "ВВЕДЕНИЕ" + , "VARIABLES": "ПЕРЕМЕННЫЕ" + , "STRINGS": "СТРОКИ" + , "STRING LENGTH": "ДЛИНА СТРОКИ" + , "REVISING STRINGS": "МОДИФИКАЦИЯ СТРОКИ" + , "NUMBERS": "ЧИСЛА" + , "ROUNDING NUMBERS": "ОКРУГЛЕНИЕ ЧИСЕЛ" + , "NUMBER TO STRING": "ЧИСЛО В СТРОКУ" + , "IF STATEMENT": "ОПЕРАТОР IF" + , "FOR LOOP": "ЦИКЛ FOR" + , "ARRAYS": "МАССИВЫ" + , "ARRAY FILTERING": "ФИЛЬТРАЦИЯ МАССИВОВ" + , "ACCESSING ARRAY VALUES": "ПОЛУЧЕНИЕ ЭЛЕМЕНТОВ МАССИВА" + , "LOOPING THROUGH ARRAYS": "ОБХОД МАССИВА В ЦИКЛЕ" + , "OBJECTS": "ОБЪЕКТЫ" + , "OBJECT PROPERTIES": "СВОЙСТВА ОБЪЕКТОВ" + , "OBJECT KEYS": "КЛЮЧИ ОБЪЕКТОВ" + , "FUNCTIONS": "ФУНКЦИИ" + , "FUNCTION ARGUMENTS": "АРГУМЕНТЫ ФУНКЦИЙ" + , "SCOPE": "ОБЛАСТЬ ВИДИМОСТИ" + } +} diff --git a/i18n/troubleshooting.md b/i18n/troubleshooting.md index 79232691..28a6e7b5 100644 --- a/i18n/troubleshooting.md +++ b/i18n/troubleshooting.md @@ -21,8 +21,7 @@ %diff% ## Additional troubleshooting: - * Did you type the name of the file correctly? You can check by running ls `%filename%`, if you see ls: cannot access `%filename%`: No such file or directory then you should create new file / rename existing or change directories to the one with file - * Make sure you didn't omit parens, since otherwise compiler would not be able to parse it - * Make sure you didn't do any typos in the string itself + * Did you type the name of the file correctly? You can check by running 'ls `%filename%`'. If you see 'ls: cannot access `%filename%`: No such file or directory,' then perhaps the file doesn't exist, or has a different name, or is in a different directory. + * Make sure you didn't omit any parens, or the compiler will not be able to parse it. + * Make sure you don't have any typos in the string itself. -> **Need help?** Ask a question at: github.com/nodeschool/discussions/issues diff --git a/i18n/troubleshooting_es.md b/i18n/troubleshooting_es.md index 61527fb9..7a30b01f 100644 --- a/i18n/troubleshooting_es.md +++ b/i18n/troubleshooting_es.md @@ -24,5 +24,3 @@ * ¿Escribiste correctamente el nombre del archivo? Lo puedes comprobar ejecutanto ls `%filename%`, si ves: ls: cannot access `%filename%`: No such file or directory entonces deberias crear un nuevo archivo, renombrar el existente o cambiar de carpeta a la que contenga el archivo * Asegúrate de no omitir paréntesis, ya que de otra manera el compilador no sería capaz de parsearlo. * Asegúrate de no cometer ningún tipo de error ortográfico - -> **¿Necesita ayuda?** Has una pregunta en: github.com/nodeschool/discussions/issues \ No newline at end of file diff --git a/i18n/troubleshooting_fr.md b/i18n/troubleshooting_fr.md new file mode 100644 index 00000000..9274c6b5 --- /dev/null +++ b/i18n/troubleshooting_fr.md @@ -0,0 +1,26 @@ +--- +# O-oh, quelque chose ne fonctionne pas. +# Mais ne paniquez pas ! +--- + +## Vérifiez votre solution : + +`Solution +===================` + +%solution% + +`Votre essai +===================` + +%attempt% + +`Différence +===================` + +%diff% + +## Autres pistes : + * Avez-vous nommé correctement le fichier ? Vous pouvez vérifier en exécutant `ls %filename%`, si vous voyez `ls: cannot access %filename%: No such file or directory` c'est que vous devriez créer un nouveau fichier ou le renommer ou aller dans le dossier contenant le fichier. + * Assurez-vous que vous n'avez pas oublié de parenthèse, sinon le compilateur ne sera pas capable d'analyser votre code. + * Assurez-vous de ne pas avoir de faute de frappe dans la chaîne de caractère. diff --git a/i18n/troubleshooting_it.md b/i18n/troubleshooting_it.md new file mode 100644 index 00000000..8ee67017 --- /dev/null +++ b/i18n/troubleshooting_it.md @@ -0,0 +1,26 @@ +--- +# Uh-oh, qualcosa non ha funzionato. +# Niente panico! +--- + +## Verifica la tua soluzione: + +`Soluzione +===================` + +%solution% + +`Il tuo tentativo +===================` + +%attempt% + +`Differenza +===================` + +%diff% + +## Risoluzione dei problemi: + * Hai scritto correttamente il nome del file? Puoi verificare eseguendo il comando ls `%filename%`; se ti viene risposto ls: cannot access `%filename%`: No such file or directory allora devi creare un nuovo file o rinominare il file esistente, o cambiare la directory di lavoro con quella contenente il file. + * Assicurati di non aver omesso delle parentesi, altrimenti l'interprete potrebbe incontrare errori nell'eseguirlo + * Assicurati di non aver commesso errori nel comando stesso diff --git a/i18n/troubleshooting_ja.md b/i18n/troubleshooting_ja.md index 3b8ecd08..2fa5e2fc 100644 --- a/i18n/troubleshooting_ja.md +++ b/i18n/troubleshooting_ja.md @@ -24,5 +24,3 @@ * ファイル名をタイプミスしていませんか? ls `%filename%` を実行すれば確認できます。もし ls: cannot access `%filename%`: No such file or directory と表示されたら、新しいファイルを作るか、すでにあるファイルの名前を変えるか、ファイルがあるディレクトリを変更する必要があるかもしれません。 * カッコを省略していませんか?省略するとコンパイラはJavaScriptファイル正しく読むことができません。 * ファイルの中身にタイプミスはありませんか? - -> **助けが必要ですか?** github.com/nodeschool/discussions/issues で質問してください \ No newline at end of file diff --git a/i18n/troubleshooting_ko.md b/i18n/troubleshooting_ko.md index 17ace923..4fe0d6ee 100644 --- a/i18n/troubleshooting_ko.md +++ b/i18n/troubleshooting_ko.md @@ -24,5 +24,3 @@ * 파일 이름을 정확히 입력하셨나요? ls `%filename%`을 실행해 확인할 수 있습니다. ls: cannot access `%filename%`: No such file or directory가 나왔다면 새 파일을 만들거나, 이미 있는 파일이나 디렉터리의 이름을 바꾸면 됩니다. * 괄호를 빼먹지 않았는지 확인하세요. 그러면 컴파일러가 파싱할 수 없습니다. * 문자열 자체에 오타가 없는지 확인하세요. - -> **도움이 필요하세요?** 여기에서 질문하세요! github.com/nodeschool/discussions/issues diff --git a/i18n/troubleshooting_nb-no.md b/i18n/troubleshooting_nb-no.md new file mode 100644 index 00000000..f495853d --- /dev/null +++ b/i18n/troubleshooting_nb-no.md @@ -0,0 +1,26 @@ +--- +# Huffda, her var det noe som ikke fungerte. +# Men ingen grunn til panikk! +--- + +## Kontroller din løsning: + +`Løsningen +===================` + +%solution% + +`Ditt forsøk +===================` + +%attempt% + +`Sammenligning +===================` + +%diff% + +## Tips til feilsøking: + * Er du sikker på at du skrev filnavnet riktig? Du kan dobbeltsjekket ved å kjøre ls `%filename%`, hvis du ser: cannot access `%filename%`: No such file or directory burde du lage filen med det navnet / gi filen nytt navn eller bytte til katalogen hvor filen er lagret + * Sjekk at du ikke ha glemt noen paranteser, det hindrer programmet å bli lest / kompileres + * Sjekk at du ikke har skrivefeil i stringen som ble skrevet ut diff --git a/i18n/troubleshooting_nl.md b/i18n/troubleshooting_nl.md new file mode 100755 index 00000000..40f9d139 --- /dev/null +++ b/i18n/troubleshooting_nl.md @@ -0,0 +1,27 @@ +--- +# Oeps, iets werkt nog niet. +# Maar... geen paniek! +--- + +## Controleer je oplossing: + +`Oplossing +===================` + +%solution% + +`Jouw oplossing +===================` + +%attempt% + +`Verschil +===================` + +%diff% + +## Aanvullende probleemoplossing:: + * Heb je de naam van het bestand correct getypt? Dit kun je controleren door dit command uit te voeren 'ls `%filename%`'. Als je dit ziet: 'ls: cannot access `%filename%`: No such file or directory,' bestaat het bestand misschien niet, heeft het een andere naam of bevindt het zich in een andere map. + * Zorg ervoor dat je geen haakjes hebt weggelaten, anders kan de compiler het niet ontcijferen. + * Zorg ervoor dat je geen typfouten in de tekst zelf hebt. + diff --git a/i18n/troubleshooting_pt-br.md b/i18n/troubleshooting_pt-br.md new file mode 100644 index 00000000..871956c8 --- /dev/null +++ b/i18n/troubleshooting_pt-br.md @@ -0,0 +1,26 @@ +--- +# Opa! Parece que algo não está funcionando. +# Mas não se desespere! +--- + +## Verifique a solução: + +`Solução +===================` + +%solution% + +`Sua tentativa +===================` + +%attempt% + +`Diferença +===================` + +%diff% + +## Solução de problemas adicionais: + * Você digitou o nome do arquivo corretamente? Certifique-se de que o nome do arquivo é `%filename%`. + * Verifique se você não se esqueceu dos parênteses, já que de outra maneira o compilador não iria conseguir ler o arquivo. + * Certifique-se de não ter cometido erros ortográficos. diff --git a/i18n/troubleshooting_ru.md b/i18n/troubleshooting_ru.md new file mode 100644 index 00000000..2e8d4693 --- /dev/null +++ b/i18n/troubleshooting_ru.md @@ -0,0 +1,26 @@ +--- +# Кажется что-то пошло не так... +# Но не стоит паниковать! +--- + +## Проверьте своё решение: + +`Ожидаемый результат +===================` + +%solution% + +`Ваш результат +===================` + +%attempt% + +`Различия +===================` + +%diff% + +## Что ещё можно проверить: + * Правильно ли набрано имя файла? Это можно проверить с помощью команды ls `%filename%`, если в ответ появилось ls: нет доступа к `%filename%`: Файл или директория не существует, тогда вам нужно создать новый / переименовать существующий файл или перейти в директорию с нужным файлом + * Удостоверьтесь, что вы не пропустили круглые скобки, так как в ином случае интерпретатор не сможет разобрать код + * Удостоверьтесь, что вы не сделали опечаток или не допустили ошибок diff --git a/i18n/troubleshooting_uk.md b/i18n/troubleshooting_uk.md new file mode 100644 index 00000000..5ba03d2c --- /dev/null +++ b/i18n/troubleshooting_uk.md @@ -0,0 +1,26 @@ +--- +# О-ох, щось не працює. +# Тільки без паніки! +--- + +## Перевірте ваш розв’язок: + +'Розв’язок +===================' + +%solution% + +'Ваша спроба +===================' + +%attempt% + +'Відмінність +===================' + +%diff% + +## Вирішення проблем: +* Чи ввели ви ім’я файлу коректно? Ви можете перевірити це запустивши ls '%filename%', якщо ви отримаєте ls: cannot access '%filename%': No such file or directory тоді вам слід створити новий файл, перейменувати чинну директорію або змінити поточну директорію на ту, яка містить потрібний файл +* Переконайтесь, що ви не забули про дужки () — через це можуть виникнути проблеми з компілятором +* Переконайтесь, що ви не допустили жодних помилок у введених рядках diff --git a/i18n/troubleshooting_zh-cn.md b/i18n/troubleshooting_zh-cn.md index d2cf3a23..9be688fa 100644 --- a/i18n/troubleshooting_zh-cn.md +++ b/i18n/troubleshooting_zh-cn.md @@ -24,5 +24,3 @@ * 确保你的文件名是正确的 * 确保你没有省略必要的括号,否则编译器将无法理解它们 * 确保你在字符串中没有笔误(可能叫键盘误更好一些) - -> **需要帮助?** 在这里提出你的问题:github.com/nodeschool/discussions/issues diff --git a/i18n/troubleshooting_zh-tw.md b/i18n/troubleshooting_zh-tw.md new file mode 100644 index 00000000..cf451ce6 --- /dev/null +++ b/i18n/troubleshooting_zh-tw.md @@ -0,0 +1,26 @@ +--- +# 啊,有東西出錯了。 +# 但是別緊張! +--- + +## 檢查你的答案: + +`正確答案 +===================` + +%solution% + +`你的答案 +===================` + +%attempt% + +`差別 +===================` + +%diff% + +## 其他錯誤排除: + * 你的檔名輸入正確了嗎?你可以透過 ls `%filename%` 指令來檢查。如果你看到了 ls: cannot access `%filename%`: No such file or directory 訊息,那可能就是檔案不存在、檔名不對或是在不同的資料夾裡。 + * 確定你沒有省略必要的括號,否則編譯器將無法理解它們。 + * 確定你在字串裡沒有打錯字。 diff --git a/i18n/uk.json b/i18n/uk.json new file mode 100644 index 00000000..8c375848 --- /dev/null +++ b/i18n/uk.json @@ -0,0 +1,24 @@ +{ + "exercise": { + "INTRODUCTION": "ВСТУП" + , "VARIABLES": "ЗМІННІ" + , "STRINGS": "РЯДКИ" + , "STRING LENGTH": "ДОВЖИНА РЯДКА" + , "REVISING STRINGS": "МОДИФІКАЦІЯ РЯДКІВ" + , "NUMBERS": "ЧИСЛА" + , "ROUNDING NUMBERS": "ОКРУГЛЕННЯ ЧИСЕЛ" + , "NUMBER TO STRING": "ЧИСЛА В РЯДКИ" + , "IF STATEMENT": "ОПЕРАТОР IF" + , "FOR LOOP": "ЦИКЛ FOR" + , "ARRAYS": "МАСИВИ" + , "ARRAY FILTERING": "ФІЛЬТРАЦІЯ МАСИВІВ" + , "ACCESSING ARRAY VALUES": "ДОСТУП ДО ЗНАЧЕНЬ МАСИВІВ" + , "LOOPING THROUGH ARRAYS": "ПРОХІД ПО МАСИВАХ" + , "OBJECTS": "ОБ'ЄКТИ" + , "OBJECT PROPERTIES": "ВЛАСТИВОСТІ ОБ'ЄКТІВ" + , "OBJECT KEYS": "КЛЮЧІ ОБ'ЄКТІВ" + , "FUNCTIONS": "ФУНКЦІЇ" + , "FUNCTION ARGUMENTS": "АРГУМЕНТИ ФУНКЦІЙ" + , "SCOPE": "ОБЛАСТЬ ВИДИМОСТІ" + } +} diff --git a/i18n/zh-tw.json b/i18n/zh-tw.json new file mode 100644 index 00000000..26d244b7 --- /dev/null +++ b/i18n/zh-tw.json @@ -0,0 +1,23 @@ +{ + "exercise": { + "INTRODUCTION": "入門" + , "VARIABLES": "變數" + , "STRINGS": "字串" + , "STRING LENGTH": "字串長度" + , "REVISING STRINGS": "修改字串" + , "NUMBERS": "數字" + , "ROUNDING NUMBERS": "數字取整數" + , "NUMBER TO STRING": "數字轉字串" + , "IF STATEMENT": "IF 條件式" + , "FOR LOOP": "FOR 迴圈" + , "ARRAYS": "陣列" + , "ARRAY FILTERING": "陣列過濾" + , "ACCESSING ARRAY VALUES": "存取陣列中的值" + , "LOOPING THROUGH ARRAYS": "以迴圈存取陣列中的值" + , "OBJECTS": "物件" + , "OBJECT PROPERTIES": "物件的屬性" + , "FUNCTIONS": "函式" + , "FUNCTION ARGUMENTS": "函式的參數" + , "SCOPE": "作用域" + } +} diff --git a/index.js b/index.js old mode 100755 new mode 100644 index 8ee37bbc..01611fc9 --- a/index.js +++ b/index.js @@ -1,19 +1,28 @@ -#!/usr/bin/env node +const path = require('path') +const fs = require('fs') +const problem = require('./lib/problem') -var path = require('path'); -var adventure = require('workshopper-adventure/adventure'); -var jsing = adventure({ - name: 'javascripting' - , appDir: __dirname - , languages: ['en', 'ja', 'ko', 'es', 'zh-cn'] -}); +const i18nDir = path.join(__dirname, 'i18n') +const languages = ['en'].concat(fs.readdirSync(i18nDir) + .filter((f) => f.match(/\w+\.json/)) + .map((f) => f.replace('.json', '')) +) +const jsing = require('workshopper-adventure')({ + appDir: __dirname, + languages, + header: require('workshopper-adventure/default/header'), + footer: require('./lib/footer.js') +}) -var problems = require('./menu.json'); +jsing.addAll(require('./menu.json').map(function (name) { + return { + name, + fn: function () { + const p = name.toLowerCase().replace(/\s/g, '-') + const dir = require('path').join(__dirname, 'problems', p) + return problem(dir) + } + } +})) -problems.forEach(function (problem) { - var p = problem.toLowerCase().replace(/\s/g, '-'); - var dir = path.join(__dirname, 'problems', p); - jsing.add(problem, function () { return require(dir); }); -}); - -jsing.execute(process.argv.slice(2)); +module.exports = jsing diff --git a/lib/compare-solution.js b/lib/compare-solution.js index 34bca4ad..fba0dc0b 100644 --- a/lib/compare-solution.js +++ b/lib/compare-solution.js @@ -1,59 +1,49 @@ -require("colors"); +require('colors') -var path = require("path"); -var diff = require("diff"); -var run = require(path.join(__dirname, "run-solution")); +const path = require('path') +const diff = require('diff') +const run = require(path.join(__dirname, 'run-solution')) -module.exports = function(solution, attempt, cb) { - - run(solution, function(err, solutionResult) { - - if(err) { - console.error(err); - return cb(false); +module.exports = function (solution, attempt, i18n, cb) { + run(solution, i18n, function (err, solutionResult) { + if (err) { + console.error(err) + return cb(err, false) } - run(attempt, function(err, attemptResult) { - - if(err && err.code !== 8) { - console.error(err); - return cb(false); + run(attempt, i18n, function (err, attemptResult) { + if (err && err.code !== 8) { + console.error(err) + return cb(err, false) } - if(solutionResult === attemptResult) { - return cb(true); + if (solutionResult === attemptResult) { + return cb(err, true) } - cb(false, { + cb(null, false, { solution: solutionResult, - attempt: err || attemptResult, - diff: generateDiff(solutionResult, attemptResult) - }); - - }); - - }); - + attempt: err || attemptResult, + diff: generateDiff(solutionResult, attemptResult) + }) + }) + }) } -function generateDiff(solution, attempt) { +function generateDiff (solution, attempt) { + const parts = diff.diffChars(solution, attempt) - var parts = diff.diffChars(solution, attempt); + let result = '' - var result = ""; - - parts.forEach(function(part) { - - if(part.added) { - result += part.value["bgRed"]; - } else if(part.removed) { - result += part.value["bgGreen"]; + parts.forEach(function (part) { + if (part.added) { + result += part.value.bgRed + } else if (part.removed) { + result += part.value.bgGreen } else { - result += part.value; + result += part.value } + }) - }); - - return result; - + return result } diff --git a/lib/footer.js b/lib/footer.js new file mode 100644 index 00000000..b51c5442 --- /dev/null +++ b/lib/footer.js @@ -0,0 +1,7 @@ +const path = require('path') +module.exports = [ + { text: '---', type: 'md' }, + { file: path.join(__dirname, '..', 'i18n', 'footer', '{lang}.md') }, + { text: '', type: 'md' }, + require('workshopper-adventure/default/footer') +] diff --git a/lib/get-file.js b/lib/get-file.js index 91d77a8a..84b79dc2 100644 --- a/lib/get-file.js +++ b/lib/get-file.js @@ -1,11 +1,9 @@ -var fs = require('fs'); -var path = require('path'); -var md = require('cli-md'); +const fs = require('fs') module.exports = function (filepath) { - return md(fs.readFileSync(filepath, 'utf8')) + return fs.readFileSync(filepath, 'utf8') .replace(/'/g, "'") .replace(/"/g, '"') .replace(/</g, '<') - .replace(/>/g, '>'); -}; + .replace(/>/g, '>') +} diff --git a/lib/problem.js b/lib/problem.js index f4f4803e..b1986af2 100644 --- a/lib/problem.js +++ b/lib/problem.js @@ -1,52 +1,51 @@ -var path = require('path'); -var getFile = require('./get-file'); -var compare = require('./compare-solution'); +const path = require('path') +const getFile = require('./get-file') +const compare = require('./compare-solution') -module.exports = function createProblem(dirname) { - var exports = {}; +module.exports = function createProblem (dirname) { + const exports = {} - var problemName = dirname.split(path.sep); - problemName = problemName[problemName.length-1]; + let problemName = dirname.split(path.sep) + let i18n + + problemName = problemName[problemName.length - 1] exports.init = function (workshopper) { - var postfix = workshopper.lang === 'en' ? '' : '_' + workshopper.lang; - this.problem = getFile(path.join(dirname, 'problem' + postfix + '.md')); - this.solution = getFile(path.join(dirname, 'solution' + postfix + '.md')); - this.solutionPath = path.resolve(dirname, "../../solutions", problemName, "index.js"); - this.troubleshootingPath = path.join(dirname, '../../i18n/troubleshooting' + postfix + '.md'); + i18n = workshopper.i18n + const postfix = workshopper.i18n.lang() === 'en' ? '' : '_' + workshopper.i18n.lang() + this.problem = { file: path.join(dirname, 'problem' + postfix + '.md') } + this.solution = { file: path.join(dirname, 'solution' + postfix + '.md') } + this.solutionPath = path.resolve(__dirname, '..', 'solutions', problemName, 'index.js') + this.troubleshootingPath = path.join(__dirname, '..', 'i18n', 'troubleshooting' + postfix + '.md') } exports.verify = function (args, cb) { - - var attemptPath = path.resolve(process.cwd(), args[0]); - compare(this.solutionPath, attemptPath, function(match, obj) { - - if(match) { - return cb(true); + const attemptPath = path.resolve(process.cwd(), args[0]) + compare(this.solutionPath, attemptPath, i18n, function (_, match, obj) { + if (match) { + return cb(null, true) } - if(!obj) { + if (!obj) { // An error occured, we've already printed an error - return; + return } - var message = getFile(this.troubleshootingPath); + let message = getFile(this.troubleshootingPath) - message = message.replace(/%solution%/g, obj.solution); - message = message.replace(/%attempt%/g, obj.attempt); - message = message.replace(/%diff%/g, obj.diff); - message = message.replace(/%filename%/g, args[0]); + message = message.replace(/%solution%/g, obj.solution) + message = message.replace(/%attempt%/g, obj.attempt) + message = message.replace(/%diff%/g, obj.diff) + message = message.replace(/%filename%/g, args[0]) - exports.fail = message; + exports.fail = [ + { text: message, type: 'md' }, + require('./footer.js') + ] - cb(false); - - }.bind(this)); - }; - - exports.run = function (args) { - require(path.resolve(process.cwd(), args[0])); - }; + cb(null, false) + }.bind(this)) + } - return exports; -} \ No newline at end of file + return exports +} diff --git a/lib/run-solution.js b/lib/run-solution.js index 068bdc7e..fea8a877 100644 --- a/lib/run-solution.js +++ b/lib/run-solution.js @@ -1,11 +1,51 @@ -var fs = require('fs'); -var path = require('path'); -var docs = path.join(__dirname, 'docs'); -var exec = require('child_process').exec; - -module.exports = function (solution, cb) { - var child = exec('node "' + solution + '"', function (error, stdout, stderr) { - if (error) return cb(error); - else cb(null, stdout); - }); -}; +const fs = require('fs') +const exec = require('child_process').exec + +/** + * @param {!string} filePath + * @return {Promise} + */ +function exists (filePath) { + return new Promise(function (resolve, reject) { + fs.stat(filePath, function (err, d) { + if (err) { + resolve(false) + } + + resolve(true) + }) + }) +} + +/** + * @param {!string} filePath + * @return {Promise} + */ +function executeSolution (filePath) { + return new Promise(function (resolve, reject) { + exec('node "' + filePath + '"', function (err, stdout, stderr) { + if (err) { + return reject(err) + } + + return resolve(stdout) + }) + }) +} + +/** + * @param {string} solutionPath + * @param {!{__: function(string, object)}} i18n + * @param {function} cb + */ +module.exports = function (solutionPath, i18n, cb) { + exists(solutionPath).then(function (solutionExists) { + if (!solutionExists) { + throw new Error(i18n.__('error.exercise.missing_file', { exerciseFile: solutionPath })) + } + + return executeSolution(solutionPath) + }).then(function (stdout) { + cb(null, stdout) + }).catch(cb) +} diff --git a/menu.json b/menu.json index b6fc2417..27046165 100644 --- a/menu.json +++ b/menu.json @@ -15,6 +15,7 @@ "LOOPING THROUGH ARRAYS", "OBJECTS", "OBJECT PROPERTIES", + "OBJECT KEYS", "FUNCTIONS", "FUNCTION ARGUMENTS", "SCOPE" diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 00000000..8b80a6e7 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,4942 @@ +{ + "name": "javascripting", + "version": "2.7.4", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "javascripting", + "version": "2.7.4", + "license": "MIT", + "dependencies": { + "colors": "1.4.0", + "diff": "^5.1.0", + "workshopper-adventure": "^7.0.0" + }, + "bin": { + "javascripting": "bin/javascripting" + }, + "devDependencies": { + "standard": "^17.1.0", + "workshopper-adventure-test": "^1.2.0" + }, + "engines": { + "node": ">=16.20.1" + } + }, + "node_modules/@eslint-community/eslint-utils": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", + "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==", + "dev": true, + "dependencies": { + "eslint-visitor-keys": "^3.3.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "peerDependencies": { + "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" + } + }, + "node_modules/@eslint-community/regexpp": { + "version": "4.5.1", + "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.5.1.tgz", + "integrity": "sha512-Z5ba73P98O1KUYCCJTUeVpja9RcGoMdncZ6T49FCUl2lN38JtCJ+3WgIDBv0AuY4WChU5PmtJmOCTlN6FZTFKQ==", + "dev": true, + "engines": { + "node": "^12.0.0 || ^14.0.0 || >=16.0.0" + } + }, + "node_modules/@eslint/eslintrc": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.3.tgz", + "integrity": "sha512-+5gy6OQfk+xx3q0d6jGZZC3f3KzAkXc/IanVxd1is/VIIziRqqt3ongQz0FiTUXqTk0c7aDB3OaFuKnuSoJicQ==", + "dev": true, + "dependencies": { + "ajv": "^6.12.4", + "debug": "^4.3.2", + "espree": "^9.5.2", + "globals": "^13.19.0", + "ignore": "^5.2.0", + "import-fresh": "^3.2.1", + "js-yaml": "^4.1.0", + "minimatch": "^3.1.2", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/@eslint/js": { + "version": "8.43.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.43.0.tgz", + "integrity": "sha512-s2UHCoiXfxMvmfzqoN+vrQ84ahUSYde9qNO1MdxmoEhyHWsfmwOpFlwYV+ePJEVc7gFnATGUi376WowX1N7tFg==", + "dev": true, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + } + }, + "node_modules/@hapi/address": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@hapi/address/-/address-2.1.4.tgz", + "integrity": "sha512-QD1PhQk+s31P1ixsX0H0Suoupp3VMXzIVMSwobR3F3MSUO2YCV0B7xqLcUw/Bh8yuvd3LhpyqLQWTNcRmp6IdQ==", + "deprecated": "Moved to 'npm install @sideway/address'" + }, + "node_modules/@hapi/bourne": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@hapi/bourne/-/bourne-1.3.2.tgz", + "integrity": "sha512-1dVNHT76Uu5N3eJNTYcvxee+jzX4Z9lfciqRRHCU27ihbUcYi+iSc2iml5Ke1LXe1SyJCLA0+14Jh4tXJgOppA==", + "deprecated": "This version has been deprecated and is no longer supported or maintained" + }, + "node_modules/@hapi/hoek": { + "version": "8.5.1", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-8.5.1.tgz", + "integrity": "sha512-yN7kbciD87WzLGc5539Tn0sApjyiGHAJgKvG9W8C7O+6c7qmoQMfVs0W4bX17eqz6C78QJqqFrtgdK5EWf6Qow==", + "deprecated": "This version has been deprecated and is no longer supported or maintained" + }, + "node_modules/@hapi/joi": { + "version": "15.1.1", + "resolved": "https://registry.npmjs.org/@hapi/joi/-/joi-15.1.1.tgz", + "integrity": "sha512-entf8ZMOK8sc+8YfeOlM8pCfg3b5+WZIKBfUaaJT8UsjAAPjartzxIYm3TIbjvA4u+u++KbcXD38k682nVHDAQ==", + "deprecated": "Switch to 'npm install joi'", + "dependencies": { + "@hapi/address": "2.x.x", + "@hapi/bourne": "1.x.x", + "@hapi/hoek": "8.x.x", + "@hapi/topo": "3.x.x" + } + }, + "node_modules/@hapi/topo": { + "version": "3.1.6", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-3.1.6.tgz", + "integrity": "sha512-tAag0jEcjwH+P2quUfipd7liWCNX2F8NvYjQp2wtInsZxnMlypdw0FtAOLxtvvkO+GSRRbmNi8m/5y42PQJYCQ==", + "deprecated": "This version has been deprecated and is no longer supported or maintained", + "dependencies": { + "@hapi/hoek": "^8.3.0" + } + }, + "node_modules/@humanwhocodes/config-array": { + "version": "0.11.10", + "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.10.tgz", + "integrity": "sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==", + "dev": true, + "dependencies": { + "@humanwhocodes/object-schema": "^1.2.1", + "debug": "^4.1.1", + "minimatch": "^3.0.5" + }, + "engines": { + "node": ">=10.10.0" + } + }, + "node_modules/@humanwhocodes/module-importer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", + "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", + "dev": true, + "engines": { + "node": ">=12.22" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" + } + }, + "node_modules/@humanwhocodes/object-schema": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz", + "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==", + "dev": true + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@sindresorhus/is": { + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-0.14.0.tgz", + "integrity": "sha512-9NET910DNaIPngYnLLPeg+Ogzqsi9uM4mSboU5y6p8S5DzMTVEsJZrawi+BoDNUVBa2DhJqQYUFvMDfgU062LQ==", + "engines": { + "node": ">=6" + } + }, + "node_modules/@szmarczak/http-timer": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-1.1.2.tgz", + "integrity": "sha512-XIB2XbzHTN6ieIjfIMV9hlVcfPU26s2vafYWQcZHWXHOxiaRZYEDKEwdl129Zyg50+foYV2jCgtrqSA6qNuNSA==", + "dependencies": { + "defer-to-connect": "^1.0.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/@types/charm": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@types/charm/-/charm-1.0.3.tgz", + "integrity": "sha512-FpNoSOkloETr+ZJ0RsZpB+a/tqJkniIN+9Enn6uPIbhiNptOWtZzV7FkaqxTRjvvlHeUKMR331Wj9tOmqG10TA==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/json5": { + "version": "0.0.29", + "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", + "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", + "dev": true + }, + "node_modules/@types/node": { + "version": "20.3.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.3.2.tgz", + "integrity": "sha512-vOBLVQeCQfIcF/2Y7eKFTqrMnizK5lRNQ7ykML/5RuwVXVWxYkgwS7xbt4B6fKCUPgbSL5FSsjHQpaGQP/dQmw==" + }, + "node_modules/abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" + }, + "node_modules/acorn": { + "version": "8.9.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.9.0.tgz", + "integrity": "sha512-jaVNAFBHNLXspO543WnNNPZFRtavh3skAkITqD0/2aeMkKZTN+254PyhwxFYrk3vQ1xfY+2wbesJMs/JC8/PwQ==", + "dev": true, + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/acorn-jsx": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", + "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", + "dev": true, + "peerDependencies": { + "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" + } + }, + "node_modules/after": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/after/-/after-0.8.2.tgz", + "integrity": "sha512-QbJ0NTQ/I9DI3uSJA4cbexiwQeRAfjPScqIbSjUDd9TOrcg6pTkdgziesOqxBMBzit8vFCTwrP27t13vFOORRA==" + }, + "node_modules/ajv": { + "version": "6.12.6", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", + "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/ansi-colors": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-3.2.3.tgz", + "integrity": "sha512-LEHHyuhlPY3TmuUYMh2oz89lTShfvgbmzaBcxve9t/9Wuy7Dwf4yoAKcND7KFT1HAQfqZ12qtc+DUrBMeKF9nw==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/ansicolors": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz", + "integrity": "sha512-QXu7BPrP29VllRxH8GwB7x5iX5qWKAAMLqKQGWTeLWVlNHNOpVMJ91dsxQAIWXpjuW5wqvxu3Jd/nRjrJ+0pqg==" + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true + }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array-includes": { + "version": "3.1.6", + "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.6.tgz", + "integrity": "sha512-sgTbLvL6cNnw24FnbaDyjmvddQ2ML8arZsgaJhoABMoplz/4QRhtrYS+alr1BUM1Bwp6dhx8vVCBSLG+StwOFw==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "get-intrinsic": "^1.1.3", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.flat": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.1.tgz", + "integrity": "sha512-roTU0KWIOmJ4DRLmwKd19Otg0/mT3qPNt0Qb3GWW8iObuZXxrjB/pzn0R3hqpRSWg4HCwqx+0vwOnWnvlOyeIA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "es-shim-unscopables": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.flatmap": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.1.tgz", + "integrity": "sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "es-shim-unscopables": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.reduce": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/array.prototype.reduce/-/array.prototype.reduce-1.0.5.tgz", + "integrity": "sha512-kDdugMl7id9COE8R7MHF5jWk7Dqt/fs4Pv+JXoICnYwqpjjjbUurz6w5fT5IG6brLdJhv6/VoHB0H7oyIBXd+Q==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.tosorted": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/array.prototype.tosorted/-/array.prototype.tosorted-1.1.1.tgz", + "integrity": "sha512-pZYPXPRl2PqWcsUs6LOMn+1f1532nEoPTYowBtqLwAW+W8vSVhkIGnmOX1t/UQjD6YGI0vcD2B1U7ZFGQH9jnQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "es-shim-unscopables": "^1.0.0", + "get-intrinsic": "^1.1.3" + } + }, + "node_modules/available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + }, + "node_modules/binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/brace-expansion": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz", + "integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==", + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", + "dev": true + }, + "node_modules/builtins": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/builtins/-/builtins-5.0.1.tgz", + "integrity": "sha512-qwVpFEHNfhYJIzNRBvd2C1kyo6jz3ZSMPyyuR47OPdiKWlbYnZNyDWuyR175qDnAJLiCo5fBBqPb3RiXgWlkOQ==", + "dev": true, + "dependencies": { + "semver": "^7.0.0" + } + }, + "node_modules/builtins/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/cacheable-request": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-6.1.0.tgz", + "integrity": "sha512-Oj3cAGPCqOZX7Rz64Uny2GYAZNliQSqfbePrgAQ1wKAihYmCUnraBtJtKcGR4xz7wF+LoJC+ssFZvv5BgF9Igg==", + "dependencies": { + "clone-response": "^1.0.2", + "get-stream": "^5.1.0", + "http-cache-semantics": "^4.0.0", + "keyv": "^3.0.0", + "lowercase-keys": "^2.0.0", + "normalize-url": "^4.1.0", + "responselike": "^1.0.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cacheable-request/node_modules/get-stream": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", + "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cacheable-request/node_modules/lowercase-keys": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz", + "integrity": "sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==", + "engines": { + "node": ">=8" + } + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/cardinal": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/cardinal/-/cardinal-1.0.0.tgz", + "integrity": "sha512-INsuF4GyiFLk8C91FPokbKTc/rwHqV4JnfatVZ6GPhguP1qmkRWX2dp5tepYboYdPpGWisLVLI+KsXoXFPRSMg==", + "dependencies": { + "ansicolors": "~0.2.1", + "redeyed": "~1.0.0" + }, + "bin": { + "cdl": "bin/cdl.js" + } + }, + "node_modules/cardinal/node_modules/ansicolors": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/ansicolors/-/ansicolors-0.2.1.tgz", + "integrity": "sha512-tOIuy1/SK/dr94ZA0ckDohKXNeBNqZ4us6PjMVLs5h1w2GBB6uPtOknp2+VF4F/zcy9LI70W+Z+pE2Soajky1w==" + }, + "node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/charm": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/charm/-/charm-1.0.2.tgz", + "integrity": "sha512-wqW3VdPnlSWT4eRiYX+hcs+C6ViBPUWk1qTCd+37qw9kEm/a5n2qcyQDMBWvSYKN/ctqZzeXNQaeBjOetJJUkw==", + "dependencies": { + "inherits": "^2.0.1" + } + }, + "node_modules/charm_inheritance-fix": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/charm_inheritance-fix/-/charm_inheritance-fix-1.0.1.tgz", + "integrity": "sha512-+uv5rxSxgmOA4sdUKFkH5/gd2CD+UKmVhXvyBz78hgrH1xU7Rr6p9Z2tLAoaMuLukwOuvAp2VOveg3Oas2LGsA==", + "dev": true + }, + "node_modules/chokidar": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz", + "integrity": "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==", + "dev": true, + "dependencies": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.2.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "optionalDependencies": { + "fsevents": "~2.1.1" + } + }, + "node_modules/chokidar/node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "dependencies": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + } + }, + "node_modules/cliui/node_modules/ansi-regex": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", + "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/cliui/node_modules/string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "dependencies": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/cliui/node_modules/strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "dependencies": { + "ansi-regex": "^4.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/clone-response": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.3.tgz", + "integrity": "sha512-ROoL94jJH2dUVML2Y/5PEDNaSHgeOdSDicUyS7izcF63G6sTc/FTjLub4b8Il9S8S0beOfYt0TaA5qvFK+w0wA==", + "dependencies": { + "mimic-response": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/colors": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", + "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==", + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/colors-tmpl": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/colors-tmpl/-/colors-tmpl-1.0.0.tgz", + "integrity": "sha512-Hx00BVcaD10ckpechE7C4ULM4BNF0TaOJKDatpomNy0qERK9yeDgokcKmpbdtBQS1dYJdtSn71BORjyMzm6IrQ==", + "deprecated": "no longer maintained", + "dependencies": { + "colors": "~1.0.2" + } + }, + "node_modules/colors-tmpl/node_modules/colors": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/colors/-/colors-1.0.3.tgz", + "integrity": "sha512-pFGrxThWcWQ2MsAz6RtgeWe4NK2kUE1WfsrvvlctdII745EW9I0yflqhe7++M5LEc7bV2c/9/5zc8sFcpL0Drw==", + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/combined-stream-wait-for-it": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/combined-stream-wait-for-it/-/combined-stream-wait-for-it-1.1.0.tgz", + "integrity": "sha512-lYbu2S3FRbV3C5anEiuESrHhN92ZoC/aKUmD6yiOwx5zun508hAkIHVOTg+uBrql/rvp/IrSc/1ccFkguA/9bA==", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/commandico": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/commandico/-/commandico-2.0.4.tgz", + "integrity": "sha512-QF9HmgaY/k9o/7hTbLeH3eP9cjKmz8QHGnqTAZ6KQ4BHt3h2m7+S2+OzSbR5Zs1qBdKMjWxOGufd/wX/pXEhew==", + "dependencies": { + "@hapi/joi": "^15.1.0", + "explicit": "^0.1.1", + "minimist": "^1.1.1" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "node_modules/cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/decompress-response": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-3.3.0.tgz", + "integrity": "sha512-BzRPQuY1ip+qDonAOz42gRm/pg9F768C+npV/4JOsxRC2sq+Rlk+Q4ZCAsOhnIaMrgarILY+RMUIvMmmX1qAEA==", + "dependencies": { + "mimic-response": "^1.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/deep-is": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", + "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", + "dev": true + }, + "node_modules/defer-to-connect": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-1.1.3.tgz", + "integrity": "sha512-0ISdNousHvZT2EiFlZeZAHBUvSxmKswVCEf8hW7KWgG4a8MVEu/3Vb6uWYozkjylyCxe0JBIiRB1jV45S70WVQ==" + }, + "node_modules/define-properties": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.0.tgz", + "integrity": "sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA==", + "dev": true, + "dependencies": { + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/diff": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-5.1.0.tgz", + "integrity": "sha512-D+mk+qE8VC/PAUrlAU34N+VfXev0ghe5ywmpqrawphmVZc1bEfn56uo9qpyGp1p4xpzOHkSW4ztBd6L7Xx4ACw==", + "engines": { + "node": ">=0.3.1" + } + }, + "node_modules/doctrine": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", + "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", + "dev": true, + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/duplexer2": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", + "integrity": "sha512-asLFVfWWtJ90ZyOUHMqk7/S2w2guQKxUI2itj3d92ADHhxUSbCMGi1f1cBcJ7xM1To+pE/Khbwo1yuNbMEPKeA==", + "dependencies": { + "readable-stream": "^2.0.2" + } + }, + "node_modules/duplexer3": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/duplexer3/-/duplexer3-0.1.5.tgz", + "integrity": "sha512-1A8za6ws41LQgv9HrE/66jyC5yuSjQ3L/KOpFtoBilsAK2iA2wuS5rTt1OCzIvtS2V7nVmedsUU+DGRcjBmOYA==" + }, + "node_modules/emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "node_modules/end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dependencies": { + "once": "^1.4.0" + } + }, + "node_modules/entities": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz", + "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==" + }, + "node_modules/error-ex": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", + "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "dev": true, + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/es-abstract": { + "version": "1.21.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.21.2.tgz", + "integrity": "sha512-y/B5POM2iBnIxCiernH1G7rC9qQoM77lLIMQLuob0zhp8C56Po81+2Nj0WFKnd0pNReDTnkYryc+zhOzpEIROg==", + "dev": true, + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.5", + "get-intrinsic": "^1.2.0", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.10", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.4.3", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.7", + "string.prototype.trimend": "^1.0.6", + "string.prototype.trimstart": "^1.0.6", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.9" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", + "dev": true + }, + "node_modules/es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "dev": true, + "dependencies": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-shim-unscopables": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.0.tgz", + "integrity": "sha512-Jm6GPcCdC30eMLbZ2x8z2WuRwAws3zTBBKuusffYVUrNj/GVSUAZ+xKMaUpfNDR5IbyNA5LJbaecoUVbmUcB1w==", + "dev": true, + "dependencies": { + "has": "^1.0.3" + } + }, + "node_modules/es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dev": true, + "dependencies": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==" + }, + "node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/eslint": { + "version": "8.43.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.43.0.tgz", + "integrity": "sha512-aaCpf2JqqKesMFGgmRPessmVKjcGXqdlAYLLC3THM8t5nBRZRQ+st5WM/hoJXkdioEXLLbXgclUpM0TXo5HX5Q==", + "dev": true, + "dependencies": { + "@eslint-community/eslint-utils": "^4.2.0", + "@eslint-community/regexpp": "^4.4.0", + "@eslint/eslintrc": "^2.0.3", + "@eslint/js": "8.43.0", + "@humanwhocodes/config-array": "^0.11.10", + "@humanwhocodes/module-importer": "^1.0.1", + "@nodelib/fs.walk": "^1.2.8", + "ajv": "^6.10.0", + "chalk": "^4.0.0", + "cross-spawn": "^7.0.2", + "debug": "^4.3.2", + "doctrine": "^3.0.0", + "escape-string-regexp": "^4.0.0", + "eslint-scope": "^7.2.0", + "eslint-visitor-keys": "^3.4.1", + "espree": "^9.5.2", + "esquery": "^1.4.2", + "esutils": "^2.0.2", + "fast-deep-equal": "^3.1.3", + "file-entry-cache": "^6.0.1", + "find-up": "^5.0.0", + "glob-parent": "^6.0.2", + "globals": "^13.19.0", + "graphemer": "^1.4.0", + "ignore": "^5.2.0", + "import-fresh": "^3.0.0", + "imurmurhash": "^0.1.4", + "is-glob": "^4.0.0", + "is-path-inside": "^3.0.3", + "js-yaml": "^4.1.0", + "json-stable-stringify-without-jsonify": "^1.0.1", + "levn": "^0.4.1", + "lodash.merge": "^4.6.2", + "minimatch": "^3.1.2", + "natural-compare": "^1.4.0", + "optionator": "^0.9.1", + "strip-ansi": "^6.0.1", + "strip-json-comments": "^3.1.0", + "text-table": "^0.2.0" + }, + "bin": { + "eslint": "bin/eslint.js" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/eslint-config-standard": { + "version": "17.1.0", + "resolved": "https://registry.npmjs.org/eslint-config-standard/-/eslint-config-standard-17.1.0.tgz", + "integrity": "sha512-IwHwmaBNtDK4zDHQukFDW5u/aTb8+meQWZvNFWkiGmbWjD6bqyuSSBxxXKkCftCUzc1zwCH2m/baCNDLGmuO5Q==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "engines": { + "node": ">=12.0.0" + }, + "peerDependencies": { + "eslint": "^8.0.1", + "eslint-plugin-import": "^2.25.2", + "eslint-plugin-n": "^15.0.0 || ^16.0.0 ", + "eslint-plugin-promise": "^6.0.0" + } + }, + "node_modules/eslint-config-standard-jsx": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/eslint-config-standard-jsx/-/eslint-config-standard-jsx-11.0.0.tgz", + "integrity": "sha512-+1EV/R0JxEK1L0NGolAr8Iktm3Rgotx3BKwgaX+eAuSX8D952LULKtjgZD3F+e6SvibONnhLwoTi9DPxN5LvvQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peerDependencies": { + "eslint": "^8.8.0", + "eslint-plugin-react": "^7.28.0" + } + }, + "node_modules/eslint-import-resolver-node": { + "version": "0.3.7", + "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.7.tgz", + "integrity": "sha512-gozW2blMLJCeFpBwugLTGyvVjNoeo1knonXAcatC6bjPBZitotxdWf7Gimr25N4c0AAOo4eOUfaG82IJPDpqCA==", + "dev": true, + "dependencies": { + "debug": "^3.2.7", + "is-core-module": "^2.11.0", + "resolve": "^1.22.1" + } + }, + "node_modules/eslint-import-resolver-node/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-module-utils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.0.tgz", + "integrity": "sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==", + "dev": true, + "dependencies": { + "debug": "^3.2.7" + }, + "engines": { + "node": ">=4" + }, + "peerDependenciesMeta": { + "eslint": { + "optional": true + } + } + }, + "node_modules/eslint-module-utils/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-plugin-es": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-es/-/eslint-plugin-es-4.1.0.tgz", + "integrity": "sha512-GILhQTnjYE2WorX5Jyi5i4dz5ALWxBIdQECVQavL6s7cI76IZTDWleTHkxz/QT3kvcs2QlGHvKLYsSlPOlPXnQ==", + "dev": true, + "dependencies": { + "eslint-utils": "^2.0.0", + "regexpp": "^3.0.0" + }, + "engines": { + "node": ">=8.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + }, + "peerDependencies": { + "eslint": ">=4.19.1" + } + }, + "node_modules/eslint-plugin-es/node_modules/eslint-utils": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz", + "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==", + "dev": true, + "dependencies": { + "eslint-visitor-keys": "^1.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + } + }, + "node_modules/eslint-plugin-es/node_modules/eslint-visitor-keys": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", + "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/eslint-plugin-import": { + "version": "2.27.5", + "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.27.5.tgz", + "integrity": "sha512-LmEt3GVofgiGuiE+ORpnvP+kAm3h6MLZJ4Q5HCyHADofsb4VzXFsRiWj3c0OFiV+3DWFh0qg3v9gcPlfc3zRow==", + "dev": true, + "dependencies": { + "array-includes": "^3.1.6", + "array.prototype.flat": "^1.3.1", + "array.prototype.flatmap": "^1.3.1", + "debug": "^3.2.7", + "doctrine": "^2.1.0", + "eslint-import-resolver-node": "^0.3.7", + "eslint-module-utils": "^2.7.4", + "has": "^1.0.3", + "is-core-module": "^2.11.0", + "is-glob": "^4.0.3", + "minimatch": "^3.1.2", + "object.values": "^1.1.6", + "resolve": "^1.22.1", + "semver": "^6.3.0", + "tsconfig-paths": "^3.14.1" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" + } + }, + "node_modules/eslint-plugin-import/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-plugin-import/node_modules/doctrine": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", + "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "dev": true, + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/eslint-plugin-n": { + "version": "15.7.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-n/-/eslint-plugin-n-15.7.0.tgz", + "integrity": "sha512-jDex9s7D/Qial8AGVIHq4W7NswpUD5DPDL2RH8Lzd9EloWUuvUkHfv4FRLMipH5q2UtyurorBkPeNi1wVWNh3Q==", + "dev": true, + "dependencies": { + "builtins": "^5.0.1", + "eslint-plugin-es": "^4.1.0", + "eslint-utils": "^3.0.0", + "ignore": "^5.1.1", + "is-core-module": "^2.11.0", + "minimatch": "^3.1.2", + "resolve": "^1.22.1", + "semver": "^7.3.8" + }, + "engines": { + "node": ">=12.22.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + }, + "peerDependencies": { + "eslint": ">=7.0.0" + } + }, + "node_modules/eslint-plugin-n/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/eslint-plugin-promise": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-6.1.1.tgz", + "integrity": "sha512-tjqWDwVZQo7UIPMeDReOpUgHCmCiH+ePnVT+5zVapL0uuHnegBUs2smM13CzOs2Xb5+MHMRFTs9v24yjba4Oig==", + "dev": true, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "peerDependencies": { + "eslint": "^7.0.0 || ^8.0.0" + } + }, + "node_modules/eslint-plugin-react": { + "version": "7.32.2", + "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.32.2.tgz", + "integrity": "sha512-t2fBMa+XzonrrNkyVirzKlvn5RXzzPwRHtMvLAtVZrt8oxgnTQaYbU6SXTOO1mwQgp1y5+toMSKInnzGr0Knqg==", + "dev": true, + "dependencies": { + "array-includes": "^3.1.6", + "array.prototype.flatmap": "^1.3.1", + "array.prototype.tosorted": "^1.1.1", + "doctrine": "^2.1.0", + "estraverse": "^5.3.0", + "jsx-ast-utils": "^2.4.1 || ^3.0.0", + "minimatch": "^3.1.2", + "object.entries": "^1.1.6", + "object.fromentries": "^2.0.6", + "object.hasown": "^1.1.2", + "object.values": "^1.1.6", + "prop-types": "^15.8.1", + "resolve": "^2.0.0-next.4", + "semver": "^6.3.0", + "string.prototype.matchall": "^4.0.8" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8" + } + }, + "node_modules/eslint-plugin-react/node_modules/doctrine": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", + "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "dev": true, + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/eslint-plugin-react/node_modules/resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "dev": true, + "dependencies": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/eslint-scope": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", + "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", + "dev": true, + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^5.2.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/eslint-utils": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz", + "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==", + "dev": true, + "dependencies": { + "eslint-visitor-keys": "^2.0.0" + }, + "engines": { + "node": "^10.0.0 || ^12.0.0 || >= 14.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + }, + "peerDependencies": { + "eslint": ">=5" + } + }, + "node_modules/eslint-utils/node_modules/eslint-visitor-keys": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz", + "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/eslint-visitor-keys": { + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz", + "integrity": "sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==", + "dev": true, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/espree": { + "version": "9.5.2", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.2.tgz", + "integrity": "sha512-7OASN1Wma5fum5SrNhFMAMJxOUAbhyfQ8dQ//PJaJbNw0URTPWqIghHWt1MmAANKhHZIYOHruW4Kw4ruUWOdGw==", + "dev": true, + "dependencies": { + "acorn": "^8.8.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^3.4.1" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/esprima": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.0.0.tgz", + "integrity": "sha512-xoBq/MIShSydNZOkjkoCEjqod963yHNXTLC40ypBhop6yPqflPz/vTinmCfSrGcywVLnSftRf6a0kJLdFdzemw==", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/esquery": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", + "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==", + "dev": true, + "dependencies": { + "estraverse": "^5.1.0" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/esrecurse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", + "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", + "dev": true, + "dependencies": { + "estraverse": "^5.2.0" + }, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/estraverse": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", + "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "dev": true, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/explicit": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/explicit/-/explicit-0.1.3.tgz", + "integrity": "sha512-Y1xrJFdIwhLwKTHDuk7IGp0iMbLlctk7tEjo3hvKvjnWaUaze5lGZf/u0IfanYVbtNogbSIdLlOmuCKP46Td7g==", + "dependencies": { + "@hapi/joi": "^15.1.0" + } + }, + "node_modules/extended-terminal-menu": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/extended-terminal-menu/-/extended-terminal-menu-3.0.3.tgz", + "integrity": "sha512-Qo99b68FeJyNCHYSLuVLP9RX9d3sTeo/Hfe8Bck/KSJ6okkduyGs08327GjztC/yCL4RtsTn5f8DwI2Mywqu4w==", + "dependencies": { + "@types/charm": "^1.0.2", + "charm": "^1.0.2", + "color-convert": "^2.0.1", + "duplexer2": "^0.1.4", + "resumer": "~0.0.0", + "supports-color": "^7.1.0", + "through2": "^4.0.2", + "wcstring": "^2.1.0" + } + }, + "node_modules/extended-terminal-menu/node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/extended-terminal-menu/node_modules/through2": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", + "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", + "dependencies": { + "readable-stream": "3" + } + }, + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "dev": true + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true + }, + "node_modules/fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", + "dev": true + }, + "node_modules/fastq": { + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.15.0.tgz", + "integrity": "sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==", + "dev": true, + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/file-entry-cache": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", + "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", + "dev": true, + "dependencies": { + "flat-cache": "^3.0.4" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "dev": true, + "dependencies": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/flat": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.1.tgz", + "integrity": "sha512-FmTtBsHskrU6FJ2VxCnsDb84wu9zhmO3cUX2kGFb5tuwhfXxGciiT0oRY+cck35QmG+NmGh5eLz6lLCpWTqwpA==", + "dev": true, + "dependencies": { + "is-buffer": "~2.0.3" + }, + "bin": { + "flat": "cli.js" + } + }, + "node_modules/flat-cache": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.0.4.tgz", + "integrity": "sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==", + "dev": true, + "dependencies": { + "flatted": "^3.1.0", + "rimraf": "^3.0.2" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "node_modules/flatted": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz", + "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==", + "dev": true + }, + "node_modules/for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "dev": true, + "dependencies": { + "is-callable": "^1.1.3" + } + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + }, + "node_modules/fsevents": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", + "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "deprecated": "\"Please update to latest v2.3 or v2.2\"", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "node_modules/function.prototype.name": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz", + "integrity": "sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3", + "es-abstract": "^1.19.0", + "functions-have-names": "^1.2.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true, + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-stdin": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-8.0.0.tgz", + "integrity": "sha512-sY22aA6xchAzprjyqmSEQv4UbAAzRN0L2dQB0NlN5acTTK9Don6nhoc3eAbUnpZiCANAMfd/+40kVdKfFygohg==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/get-stream": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", + "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/glob-parent": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", + "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.3" + }, + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/globals": { + "version": "13.20.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", + "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", + "dev": true, + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "dev": true, + "dependencies": { + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dev": true, + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/got": { + "version": "9.6.0", + "resolved": "https://registry.npmjs.org/got/-/got-9.6.0.tgz", + "integrity": "sha512-R7eWptXuGYxwijs0eV+v3o6+XH1IqVK8dJOEecQfTmkncw9AV4dcw/Dhxi8MdlqPthxxpZyizMzyg8RTmEsG+Q==", + "dependencies": { + "@sindresorhus/is": "^0.14.0", + "@szmarczak/http-timer": "^1.1.2", + "cacheable-request": "^6.0.0", + "decompress-response": "^3.3.0", + "duplexer3": "^0.1.4", + "get-stream": "^4.1.0", + "lowercase-keys": "^1.0.1", + "mimic-response": "^1.0.1", + "p-cancelable": "^1.0.0", + "to-readable-stream": "^1.0.0", + "url-parse-lax": "^3.0.0" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true + }, + "node_modules/graphemer": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", + "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", + "dev": true + }, + "node_modules/growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", + "dev": true, + "engines": { + "node": ">=4.x" + } + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "dev": true, + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-ansi/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "dev": true, + "dependencies": { + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "dev": true, + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true, + "bin": { + "he": "bin/he" + } + }, + "node_modules/http-cache-semantics": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", + "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==" + }, + "node_modules/i18n-core": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/i18n-core/-/i18n-core-3.2.0.tgz", + "integrity": "sha512-4tNStjxSyIcmOip3Ry6OHhHLPNuNjXtl5TCnFCXMO10kbjLA6SV4ZCkzTCK4vN3NyD7kOEwmbI9uHgXdiHk0hw==", + "dependencies": { + "escape-html": "^1.0.3" + } + }, + "node_modules/ignore": { + "version": "5.2.4", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz", + "integrity": "sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, + "node_modules/import-fresh": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", + "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", + "dev": true, + "dependencies": { + "parent-module": "^1.0.0", + "resolve-from": "^4.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", + "dev": true, + "engines": { + "node": ">=0.8.19" + } + }, + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==" + }, + "node_modules/internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "dev": true, + "dependencies": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", + "dev": true + }, + "node_modules/is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "dev": true, + "dependencies": { + "has-bigints": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-buffer": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.5.tgz", + "integrity": "sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "engines": { + "node": ">=4" + } + }, + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-core-module": { + "version": "2.12.1", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.12.1.tgz", + "integrity": "sha512-Q4ZuBAe2FUsKtyQJoQHlvP8OvBERxO3jEmy1I7hcRXcJBGGHFh/aJBswbXuS9sgrDH2QUO8ilkwNPHvHMd8clg==", + "dev": true, + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "dev": true, + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dev": true, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "dev": true, + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-path-inside": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", + "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "dev": true, + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "dev": true, + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.10", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.10.tgz", + "integrity": "sha512-PJqgEHiWZvMpaFZ3uTc8kHPM4+4ADTlDniuQL7cU/UDA0Ql7F70yGfHph3cLNe+c9toaigv+DFzTJKhc2CtO6A==", + "dev": true, + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dev": true, + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/json-buffer": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.0.tgz", + "integrity": "sha512-CuUqjv0FUZIdXkHPI8MezCnFCdaTAacej1TZYulLoAg1h/PhwkdXFN4V/gzY4g+fMBCOV2xF+rp7t2XD2ns/NQ==" + }, + "node_modules/json-parse-better-errors": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", + "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", + "dev": true + }, + "node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true + }, + "node_modules/json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", + "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", + "dev": true + }, + "node_modules/json5": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", + "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", + "dev": true, + "dependencies": { + "minimist": "^1.2.0" + }, + "bin": { + "json5": "lib/cli.js" + } + }, + "node_modules/jsx-ast-utils": { + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.3.tgz", + "integrity": "sha512-fYQHZTZ8jSfmWZ0iyzfwiU4WDX4HpHbMCZ3gPlWYiCl3BoeOTsqKBqnTVfH2rYT7eP5c3sVbeSPHnnJOaTrWiw==", + "dev": true, + "dependencies": { + "array-includes": "^3.1.5", + "object.assign": "^4.1.3" + }, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/keyv": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-3.1.0.tgz", + "integrity": "sha512-9ykJ/46SN/9KPM/sichzQ7OvXyGDYKGTaDlKMGCAlg2UK8KRy4jb0d8sFc+0Tt0YYnThq8X2RZgCg74RPxgcVA==", + "dependencies": { + "json-buffer": "3.0.0" + } + }, + "node_modules/latest-version": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/latest-version/-/latest-version-5.1.0.tgz", + "integrity": "sha512-weT+r0kTkRQdCdYCNtkMwWXQTMEswKrFBkm4ckQOMVhhqhIMI1UT2hMj+1iigIhgSZm5gTmrRXBNoGUgaTY1xA==", + "dependencies": { + "package-json": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/levn": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", + "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", + "dev": true, + "dependencies": { + "prelude-ls": "^1.2.1", + "type-check": "~0.4.0" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/load-json-file": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-5.3.0.tgz", + "integrity": "sha512-cJGP40Jc/VXUsp8/OrnyKyTZ1y6v/dphm3bioS+RrKXjK2BB6wHUd6JptZEFDGgGahMT+InnZO5i1Ei9mpC8Bw==", + "dev": true, + "dependencies": { + "graceful-fs": "^4.1.15", + "parse-json": "^4.0.0", + "pify": "^4.0.1", + "strip-bom": "^3.0.0", + "type-fest": "^0.3.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/load-json-file/node_modules/type-fest": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.3.1.tgz", + "integrity": "sha512-cUGJnCdr4STbePCgqNFbpVNCepa+kAVohJs1sLhxzdH+gnEoOd8VhbYa7pD3zZYGiURWM2xzEII3fQcRizDkYQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "dependencies": { + "p-locate": "^5.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, + "node_modules/lodash.merge": { + "version": "4.6.2", + "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", + "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", + "dev": true + }, + "node_modules/log-symbols": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", + "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", + "dev": true, + "dependencies": { + "chalk": "^2.4.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/log-symbols/node_modules/ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/log-symbols/node_modules/chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/log-symbols/node_modules/color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/log-symbols/node_modules/color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "dev": true + }, + "node_modules/log-symbols/node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/log-symbols/node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/log-symbols/node_modules/supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "dev": true, + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "node_modules/lowercase-keys": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-1.0.1.tgz", + "integrity": "sha512-G2Lj61tXDnVFFOi8VZds+SoQjtQC3dgokKdDG2mTm1tx4m50NUHBOZSBwQQHyy0V12A0JTG4icfZQH+xPyh8VA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/marked": { + "version": "0.3.12", + "resolved": "https://registry.npmjs.org/marked/-/marked-0.3.12.tgz", + "integrity": "sha512-k4NaW+vS7ytQn6MgJn3fYpQt20/mOgYM5Ft9BYMfQJDz2QT6yEeS9XJ8k2Nw8JTeWK/znPPW2n3UJGzyYEiMoA==", + "bin": { + "marked": "bin/marked" + } + }, + "node_modules/mimic-response": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", + "integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==", + "engines": { + "node": ">=4" + } + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/mkdirp": { + "version": "0.5.5", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", + "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", + "dev": true, + "dependencies": { + "minimist": "^1.2.5" + }, + "bin": { + "mkdirp": "bin/cmd.js" + } + }, + "node_modules/mocha": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-7.2.0.tgz", + "integrity": "sha512-O9CIypScywTVpNaRrCAgoUnJgozpIofjKUYmJhiCIJMiuYnLI6otcb1/kpW9/n/tJODHGZ7i8aLQoDVsMtOKQQ==", + "dev": true, + "dependencies": { + "ansi-colors": "3.2.3", + "browser-stdout": "1.3.1", + "chokidar": "3.3.0", + "debug": "3.2.6", + "diff": "3.5.0", + "escape-string-regexp": "1.0.5", + "find-up": "3.0.0", + "glob": "7.1.3", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.13.1", + "log-symbols": "3.0.0", + "minimatch": "3.0.4", + "mkdirp": "0.5.5", + "ms": "2.1.1", + "node-environment-flags": "1.0.6", + "object.assign": "4.1.0", + "strip-json-comments": "2.0.1", + "supports-color": "6.0.0", + "which": "1.3.1", + "wide-align": "1.1.3", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.0" + }, + "bin": { + "_mocha": "bin/_mocha", + "mocha": "bin/mocha" + }, + "engines": { + "node": ">= 8.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/mochajs" + } + }, + "node_modules/mocha/node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/mocha/node_modules/debug": { + "version": "3.2.6", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", + "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", + "deprecated": "Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/mocha/node_modules/diff": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", + "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", + "dev": true, + "engines": { + "node": ">=0.3.1" + } + }, + "node_modules/mocha/node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/mocha/node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/mocha/node_modules/find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "dependencies": { + "locate-path": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/mocha/node_modules/glob": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", + "integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + } + }, + "node_modules/mocha/node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/mocha/node_modules/js-yaml": { + "version": "3.13.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", + "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", + "dev": true, + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/mocha/node_modules/locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "dependencies": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/mocha/node_modules/minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/mocha/node_modules/ms": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", + "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==", + "dev": true + }, + "node_modules/mocha/node_modules/object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "dependencies": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/mocha/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/mocha/node_modules/p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "dependencies": { + "p-limit": "^2.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/mocha/node_modules/path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/mocha/node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/mocha/node_modules/supports-color": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.0.0.tgz", + "integrity": "sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/mocha/node_modules/which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "which": "bin/which" + } + }, + "node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/msee": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/msee/-/msee-0.3.5.tgz", + "integrity": "sha512-4ujQAsunNBX8AVN6nyiIj4jW3uHQsY3xpFVKTzbjKiq57C6GXh0h12qYehXwLYItmhpgWRB3W8PnzODKWxwXxA==", + "dependencies": { + "ansi-regex": "^3.0.0", + "ansicolors": "^0.3.2", + "cardinal": "^1.0.0", + "chalk": "^2.3.1", + "combined-stream-wait-for-it": "^1.1.0", + "entities": "^1.1.1", + "marked": "0.3.12", + "nopt": "^4.0.1", + "strip-ansi": "^4.0.0", + "table-header": "^0.2.2", + "text-table": "^0.2.0", + "through2": "^2.0.3", + "wcstring": "^2.1.0", + "xtend": "^4.0.0" + }, + "bin": { + "msee": "bin/msee" + } + }, + "node_modules/msee/node_modules/ansi-regex": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", + "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", + "engines": { + "node": ">=4" + } + }, + "node_modules/msee/node_modules/ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/msee/node_modules/chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/msee/node_modules/color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/msee/node_modules/color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" + }, + "node_modules/msee/node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/msee/node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "engines": { + "node": ">=4" + } + }, + "node_modules/msee/node_modules/strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==", + "dependencies": { + "ansi-regex": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/msee/node_modules/supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/msee/node_modules/through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "dependencies": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + } + }, + "node_modules/natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", + "dev": true + }, + "node_modules/node-environment-flags": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/node-environment-flags/-/node-environment-flags-1.0.6.tgz", + "integrity": "sha512-5Evy2epuL+6TM0lCQGpFIj6KwiEsGh1SrHUhTbNX+sLbBtjidPZFAnVK9y5yU1+h//RitLbRHTIMyxQPtxMdHw==", + "dev": true, + "dependencies": { + "object.getownpropertydescriptors": "^2.0.3", + "semver": "^5.7.0" + } + }, + "node_modules/node-environment-flags/node_modules/semver": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", + "dev": true, + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/nopt": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.3.tgz", + "integrity": "sha512-CvaGwVMztSMJLOeXPrez7fyfObdZqNUK1cPAEzLHrTybIua9pMdmmPR5YwtfNftIOMv3DPUhFaxsZMNTQO20Kg==", + "dependencies": { + "abbrev": "1", + "osenv": "^0.1.4" + }, + "bin": { + "nopt": "bin/nopt.js" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/normalize-url": { + "version": "4.5.1", + "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-4.5.1.tgz", + "integrity": "sha512-9UZCFRHQdNrfTpGg8+1INIg93B6zE0aXMVFkw1WFwvO4SlZywU6aLg5Of0Ap/PgcbSw4LNxvMWXMeugwMCX0AA==", + "engines": { + "node": ">=8" + } + }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.entries": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/object.entries/-/object.entries-1.1.6.tgz", + "integrity": "sha512-leTPzo4Zvg3pmbQ3rDK69Rl8GQvIqMWubrkxONG9/ojtFE2rD9fjMKfSI5BxW3osRH1m6VdzmqK8oAY9aT4x5w==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.fromentries": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/object.fromentries/-/object.fromentries-2.0.6.tgz", + "integrity": "sha512-VciD13dswC4j1Xt5394WR4MzmAQmlgN72phd/riNp9vtD7tp4QQWJ0R4wvclXcafgcYK8veHRed2W6XeGBvcfg==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.getownpropertydescriptors": { + "version": "2.1.6", + "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.6.tgz", + "integrity": "sha512-lq+61g26E/BgHv0ZTFgRvi7NMEPuAxLkFU7rukXjc/AlwH4Am5xXVnIXy3un1bg/JPbXHrixRkK1itUzzPiIjQ==", + "dev": true, + "dependencies": { + "array.prototype.reduce": "^1.0.5", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.21.2", + "safe-array-concat": "^1.0.0" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.hasown": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/object.hasown/-/object.hasown-1.1.2.tgz", + "integrity": "sha512-B5UIT3J1W+WuWIU55h0mjlwaqxiE5vYENJXIXZ4VFe05pNYrkKuK0U/6aFcb0pKywYJh7IhfoqUfKVmrJJHZHw==", + "dev": true, + "dependencies": { + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.values": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.1.6.tgz", + "integrity": "sha512-FVVTkD1vENCsAcwNs9k6jea2uHC/X0+JcjG8YA60FN5CMaJmG95wT9jek/xX9nornqGRrBkKtzuAu2wuHpKqvw==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/optionator": { + "version": "0.9.1", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz", + "integrity": "sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw==", + "dev": true, + "dependencies": { + "deep-is": "^0.1.3", + "fast-levenshtein": "^2.0.6", + "levn": "^0.4.1", + "prelude-ls": "^1.2.1", + "type-check": "^0.4.0", + "word-wrap": "^1.2.3" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/os-homedir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "integrity": "sha512-B5JU3cabzk8c67mRRd3ECmROafjYMXbuzlwtqdM8IbS8ktlTix8aFGb2bAGKrSRIlnfKwovGUUr72JUPyOb6kQ==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/osenv": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", + "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", + "dependencies": { + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" + } + }, + "node_modules/p-cancelable": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-1.1.0.tgz", + "integrity": "sha512-s73XxOZ4zpt1edZYZzvhqFa6uvQc1vwUa0K0BdtIZgQMAJj9IbebH+JkgKZc9h+B05PKHLOTl4ajG1BmNrVZlw==", + "engines": { + "node": ">=6" + } + }, + "node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "dependencies": { + "p-limit": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/package-json": { + "version": "6.5.0", + "resolved": "https://registry.npmjs.org/package-json/-/package-json-6.5.0.tgz", + "integrity": "sha512-k3bdm2n25tkyxcjSKzB5x8kfVxlMdgsbPr0GkZcwHsLpba6cBjqCt1KlcChKEvxHIcTB1FVMuwoijZ26xex5MQ==", + "dependencies": { + "got": "^9.6.0", + "registry-auth-token": "^4.0.0", + "registry-url": "^5.0.0", + "semver": "^6.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/parent-module": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", + "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", + "dev": true, + "dependencies": { + "callsites": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/parse-json": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", + "integrity": "sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==", + "dev": true, + "dependencies": { + "error-ex": "^1.3.1", + "json-parse-better-errors": "^1.0.1" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pify": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", + "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/pkg-conf": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/pkg-conf/-/pkg-conf-3.1.0.tgz", + "integrity": "sha512-m0OTbR/5VPNPqO1ph6Fqbj7Hv6QU7gR/tQW40ZqrL1rjgCU85W6C1bJn0BItuJqnR98PWzw7Z8hHeChD1WrgdQ==", + "dev": true, + "dependencies": { + "find-up": "^3.0.0", + "load-json-file": "^5.2.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/pkg-conf/node_modules/find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "dependencies": { + "locate-path": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/pkg-conf/node_modules/locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "dependencies": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/pkg-conf/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pkg-conf/node_modules/p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "dependencies": { + "p-limit": "^2.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/pkg-conf/node_modules/path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/prelude-ls": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", + "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/prepend-http": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/prepend-http/-/prepend-http-2.0.0.tgz", + "integrity": "sha512-ravE6m9Atw9Z/jjttRUZ+clIXogdghyZAuWJ3qEzjT+jI/dL1ifAqhZeC5VHzQp1MSt1+jxKkFNemj/iO7tVUA==", + "engines": { + "node": ">=4" + } + }, + "node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "node_modules/prop-types": { + "version": "15.8.1", + "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz", + "integrity": "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==", + "dev": true, + "dependencies": { + "loose-envify": "^1.4.0", + "object-assign": "^4.1.1", + "react-is": "^16.13.1" + } + }, + "node_modules/pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "node_modules/punycode": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.0.tgz", + "integrity": "sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/rc": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/rc/node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "dev": true + }, + "node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/readdirp": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz", + "integrity": "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==", + "dev": true, + "dependencies": { + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/redeyed": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/redeyed/-/redeyed-1.0.1.tgz", + "integrity": "sha512-8eEWsNCkV2rvwKLS1Cvp5agNjMhwRe2um+y32B2+3LqOzg4C9BBPs6vzAfV16Ivb8B9HPNKIqd8OrdBws8kNlQ==", + "dependencies": { + "esprima": "~3.0.0" + } + }, + "node_modules/regexp.prototype.flags": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz", + "integrity": "sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "functions-have-names": "^1.2.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/regexpp": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz", + "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + } + }, + "node_modules/registry-auth-token": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/registry-auth-token/-/registry-auth-token-4.2.2.tgz", + "integrity": "sha512-PC5ZysNb42zpFME6D/XlIgtNGdTl8bBOCw90xQLVMpzuuubJKYDWFAEuUNc+Cn8Z8724tg2SDhDRrkVEsqfDMg==", + "dependencies": { + "rc": "1.2.8" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/registry-url": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/registry-url/-/registry-url-5.1.0.tgz", + "integrity": "sha512-8acYXXTI0AkQv6RAOjE3vOaIXZkT9wo4LOFbBKYQEEnnMNBpKqdUrI6S4NT0KPIo/WVvJ5tE/X5LF/TQUf0ekw==", + "dependencies": { + "rc": "^1.2.8" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, + "node_modules/resolve": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.2.tgz", + "integrity": "sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g==", + "dev": true, + "dependencies": { + "is-core-module": "^2.11.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/resolve-from": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", + "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/responselike": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/responselike/-/responselike-1.0.2.tgz", + "integrity": "sha512-/Fpe5guzJk1gPqdJLJR5u7eG/gNY4nImjbRDaVWVMRhne55TCmj2i9Q+54PBRfatRC8v/rIiv9BN0pMd9OV5EQ==", + "dependencies": { + "lowercase-keys": "^1.0.0" + } + }, + "node_modules/resumer": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/resumer/-/resumer-0.0.0.tgz", + "integrity": "sha512-Fn9X8rX8yYF4m81rZCK/5VmrmsSbqS/i3rDLl6ZZHAXgC2nTAx3dhwG8q8odP/RmdLa2YrybDJaAMg+X1ajY3w==", + "dependencies": { + "through": "~2.3.4" + } + }, + "node_modules/reusify": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", + "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "dev": true, + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, + "node_modules/rimraf": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", + "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/run-parallel": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", + "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "queue-microtask": "^1.2.2" + } + }, + "node_modules/safe-array-concat": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz", + "integrity": "sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safe-array-concat/node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "dev": true + }, + "node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", + "dev": true + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/simple-terminal-menu": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/simple-terminal-menu/-/simple-terminal-menu-2.0.0.tgz", + "integrity": "sha512-m9TpPbiYkHnq0FktmYpvcELiHFP7I9TF9hDxa37nv8CODKDHdCUxHoAa1krso3ULtAexhrlAI5UjEUA/DDbpNg==", + "dependencies": { + "ansi-styles": "^4.2.1", + "extended-terminal-menu": "^3.0.3", + "wcstring": "^2.1.0" + } + }, + "node_modules/split": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.1.tgz", + "integrity": "sha512-mTyOoPbrivtXnwnIxZRFYRrPNtEFKlpB2fvjSnCQUiAA6qAZzqwna5envK4uk6OIeP17CsdF3rSBGYVBsU0Tkg==", + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "dev": true + }, + "node_modules/standard": { + "version": "17.1.0", + "resolved": "https://registry.npmjs.org/standard/-/standard-17.1.0.tgz", + "integrity": "sha512-jaDqlNSzLtWYW4lvQmU0EnxWMUGQiwHasZl5ZEIwx3S/ijZDjZOzs1y1QqKwKs5vqnFpGtizo4NOYX2s0Voq/g==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "eslint": "^8.41.0", + "eslint-config-standard": "17.1.0", + "eslint-config-standard-jsx": "^11.0.0", + "eslint-plugin-import": "^2.27.5", + "eslint-plugin-n": "^15.7.0", + "eslint-plugin-promise": "^6.1.1", + "eslint-plugin-react": "^7.32.2", + "standard-engine": "^15.0.0", + "version-guard": "^1.1.1" + }, + "bin": { + "standard": "bin/cmd.cjs" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + } + }, + "node_modules/standard-engine": { + "version": "15.1.0", + "resolved": "https://registry.npmjs.org/standard-engine/-/standard-engine-15.1.0.tgz", + "integrity": "sha512-VHysfoyxFu/ukT+9v49d4BRXIokFRZuH3z1VRxzFArZdjSCFpro6rEIU3ji7e4AoAtuSfKBkiOmsrDqKW5ZSRw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "get-stdin": "^8.0.0", + "minimist": "^1.2.6", + "pkg-conf": "^3.1.0", + "xdg-basedir": "^4.0.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + } + }, + "node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/string-to-stream": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/string-to-stream/-/string-to-stream-3.0.1.tgz", + "integrity": "sha512-Hl092MV3USJuUCC6mfl9sPzGloA3K5VwdIeJjYIkXY/8K+mUvaeEabWJgArp+xXrsWxCajeT2pc4axbVhIZJyg==", + "dependencies": { + "readable-stream": "^3.4.0" + } + }, + "node_modules/string-to-stream/node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "dependencies": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/string-width/node_modules/ansi-regex": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", + "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/string-width/node_modules/strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==", + "dev": true, + "dependencies": { + "ansi-regex": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/string.prototype.matchall": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/string.prototype.matchall/-/string.prototype.matchall-4.0.8.tgz", + "integrity": "sha512-6zOCOcJ+RJAQshcTvXPHoxoQGONa3e/Lqx90wUA+wEzX78sg5Bo+1tQo4N0pohS0erG9qtCqJDjNCQBjeWVxyg==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.3", + "regexp.prototype.flags": "^1.4.3", + "side-channel": "^1.0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trim": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz", + "integrity": "sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimend": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz", + "integrity": "sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimstart": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz", + "integrity": "sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-bom": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", + "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/strip-json-comments": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", + "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/table-header": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/table-header/-/table-header-0.2.2.tgz", + "integrity": "sha512-CD2ls9F2Y3f2dHcpJTg1OHUE/JqOIsjCbetroRT7W/vbRsjMnpmo6HR2Jz5EQgEgrjIfbV5pcQpZZFLIsWcDnw==", + "dependencies": { + "repeat-string": "^1.5.2" + } + }, + "node_modules/text-table": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", + "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==" + }, + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "node_modules/through2": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/through2/-/through2-3.0.2.tgz", + "integrity": "sha512-enaDQ4MUyP2W6ZyT6EsMzqBPZaM/avg8iuo+l2d3QCs0J+6RaqkHV/2/lOwDTueBHeJ/2LG9lrLW3d5rWPucuQ==", + "dependencies": { + "inherits": "^2.0.4", + "readable-stream": "2 || 3" + } + }, + "node_modules/to-readable-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/to-readable-stream/-/to-readable-stream-1.0.0.tgz", + "integrity": "sha512-Iq25XBt6zD5npPhlLVXGFN3/gyR2/qODcKNNyTMd4vbm39HUaOiAM4PMq0eMVC/Tkxz+Zjdsc55g9yyz+Yq00Q==", + "engines": { + "node": ">=6" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/tsconfig-paths": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.2.tgz", + "integrity": "sha512-o/9iXgCYc5L/JxCHPe3Hvh8Q/2xm5Z+p18PESBU6Ff33695QnCHBEjcytY2q19ua7Mbl/DavtBOLq+oG0RCL+g==", + "dev": true, + "dependencies": { + "@types/json5": "^0.0.29", + "json5": "^1.0.2", + "minimist": "^1.2.6", + "strip-bom": "^3.0.0" + } + }, + "node_modules/type-check": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", + "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", + "dev": true, + "dependencies": { + "prelude-ls": "^1.2.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/uri-js": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", + "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", + "dev": true, + "dependencies": { + "punycode": "^2.1.0" + } + }, + "node_modules/url-parse-lax": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/url-parse-lax/-/url-parse-lax-3.0.0.tgz", + "integrity": "sha512-NjFKA0DidqPa5ciFcSrXnAltTtzz84ogy+NebPvfEgAck0+TNg4UJ4IN+fB7zRZfbgUf0syOo9MDxFkDSMuFaQ==", + "dependencies": { + "prepend-http": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "node_modules/varsize-string": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/varsize-string/-/varsize-string-2.2.2.tgz", + "integrity": "sha512-Wuq8/cNzDSWYYQ1KlTk6IyGrRJOMU1YX21RSgEl3psbAGdExTBOIDWd80Z1n74A/24kStNT9QgylJHVjqgRpsQ==" + }, + "node_modules/version-guard": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/version-guard/-/version-guard-1.1.1.tgz", + "integrity": "sha512-MGQLX89UxmYHgDvcXyjBI0cbmoW+t/dANDppNPrno64rYr8nH4SHSuElQuSYdXGEs0mUzdQe1BY+FhVPNsAmJQ==", + "dev": true, + "engines": { + "node": ">=0.10.48" + } + }, + "node_modules/wcsize": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wcsize/-/wcsize-1.0.0.tgz", + "integrity": "sha512-80ziCk3Z+iLfhgAbMBMU+PjoSFi9dg0FIKYd9xRiF15wfwJlzxu1mdIUdIv9iE1gpkX/4hV2QBbkNlydXgEFMA==" + }, + "node_modules/wcstring": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/wcstring/-/wcstring-2.1.1.tgz", + "integrity": "sha512-81yoFUY/2Fw4RFzIkrlC47g7023/XkKofj62CNFT1kdZn6z7o2xhz8ffR7Wat76SuJTmrFNLmGDd7FLaZsIo5A==", + "dependencies": { + "varsize-string": "^2.2.1", + "wcsize": "^1.0.0" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "dev": true, + "dependencies": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-module": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.1.tgz", + "integrity": "sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==", + "dev": true + }, + "node_modules/which-typed-array": { + "version": "1.1.9", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.9.tgz", + "integrity": "sha512-w9c4xkx6mPidwp7180ckYWfMmvxpjlZuIudNtDf4N/tTAUB8VJbX25qZoAsrtGuYNnGw3pa0AXgbGKRB8/EceA==", + "dev": true, + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "dev": true, + "dependencies": { + "string-width": "^1.0.2 || 2" + } + }, + "node_modules/word-wrap": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.4.tgz", + "integrity": "sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/workshopper-adventure": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/workshopper-adventure/-/workshopper-adventure-7.0.0.tgz", + "integrity": "sha512-G1NuuxtT+AMg+ybxvhhv9J67NRsLLCy3erM3m4fErOS+MdcwrqKejrlAz8K7T/Q/SYxR/gMNZFX+xV01Ejxskg==", + "dependencies": { + "after": "^0.8.2", + "chalk": "^3.0.0", + "colors-tmpl": "~1.0.0", + "combined-stream-wait-for-it": "^1.1.0", + "commandico": "^2.0.4", + "i18n-core": "^3.0.0", + "latest-version": "^5.1.0", + "msee": "^0.3.5", + "simple-terminal-menu": "^2.0.0", + "split": "^1.0.0", + "string-to-stream": "^3.0.1", + "strip-ansi": "^6.0.0", + "through2": "^3.0.1", + "workshopper-adventure-storage": "^3.0.0" + } + }, + "node_modules/workshopper-adventure-storage": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/workshopper-adventure-storage/-/workshopper-adventure-storage-3.0.1.tgz", + "integrity": "sha512-IyJOlz6Ihzj+S4uFhI9esVRpkKWmZT65LvLB0JT4Hq4jHnxpS+ml7EMX0CxTcN3QAoUUOEDu6D30g9qSMXXREg==", + "dependencies": { + "rimraf": "^3.0.2" + } + }, + "node_modules/workshopper-adventure-test": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/workshopper-adventure-test/-/workshopper-adventure-test-1.2.0.tgz", + "integrity": "sha512-Y4Vr8gi0/BYEjzz53rSpCbDuoDdm/thWq3gxpxrgsSbg5EnhPddQQw/+TUdtvissZKBt82IR+RptG1MNtlFg0A==", + "dev": true, + "dependencies": { + "glob": "^7.1.6", + "lodash": "^4.17.15", + "mocha": "^7.1.1", + "rimraf": "^3.0.2", + "workshopper-adventure": "^6.1.0" + }, + "bin": { + "workshopper-adventure-test": "bin/workshopper-adventure-test" + } + }, + "node_modules/workshopper-adventure-test/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/chalk": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", + "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/workshopper-adventure-test/node_modules/duplexer2": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.0.2.tgz", + "integrity": "sha512-+AWBwjGadtksxjOQSFDhPNQbed7icNXApT4+2BNpsXzcCBiInq2H9XW0O8sfHFaPmnQRs7cg/P0fAr2IWQSW0g==", + "dev": true, + "dependencies": { + "readable-stream": "~1.1.9" + } + }, + "node_modules/workshopper-adventure-test/node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/extended-terminal-menu": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/extended-terminal-menu/-/extended-terminal-menu-2.1.4.tgz", + "integrity": "sha512-Jn/mlam8C8cW3KOpv5cwc01EtwcUiHtJTzgHemj+G53hmmpIJDFQOmOfgpRErmejudzdT5ajAZF6342isucBVw==", + "dev": true, + "dependencies": { + "charm_inheritance-fix": "^1.0.1", + "duplexer2": "0.0.2", + "inherits": "~2.0.0", + "resumer": "~0.0.0", + "through2": "^0.6.3", + "wcstring": "^2.1.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/extended-terminal-menu/node_modules/readable-stream": { + "version": "1.0.34", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", + "integrity": "sha512-ok1qVCJuRkNmvebYikljxJA/UEsKwLl2nI1OmaqAu4/UE+h0wKCHok4XkL/gvi39OacXvw59RJUOFUkDib2rHg==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "node_modules/workshopper-adventure-test/node_modules/extended-terminal-menu/node_modules/through2": { + "version": "0.6.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-0.6.5.tgz", + "integrity": "sha512-RkK/CCESdTKQZHdmKICijdKKsCRVHs5KsLZ6pACAmF/1GPUQhonHSXWNERctxEp7RmvjdNbZTL5z9V7nSCXKcg==", + "dev": true, + "dependencies": { + "readable-stream": ">=1.0.33-1 <1.1.0-0", + "xtend": ">=4.0.0 <4.1.0-0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ==", + "dev": true + }, + "node_modules/workshopper-adventure-test/node_modules/readable-stream": { + "version": "1.1.14", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", + "integrity": "sha512-+MeVjFf4L44XUkhM1eYbD8fyEsxcV81pqMSR5gblfcLCHfZvbrqy4/qYHE+/R5HoBUT11WV5O08Cr1n3YXkWVQ==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "node_modules/workshopper-adventure-test/node_modules/simple-terminal-menu": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/simple-terminal-menu/-/simple-terminal-menu-1.1.3.tgz", + "integrity": "sha512-UxbdVZ2qKPq5AZ3ZxWvkiUZjn5glDgMh5uMjBYBenhXsp0WQOYGUJtz8DTwVcoEnCC6Mhwr33E4aFd6XNgxh5w==", + "dev": true, + "dependencies": { + "chalk": "^1.1.1", + "extended-terminal-menu": "^2.1.2", + "wcstring": "^2.1.0", + "xtend": "^4.0.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/simple-terminal-menu/node_modules/ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/simple-terminal-menu/node_modules/chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "dev": true, + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/simple-terminal-menu/node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/simple-terminal-menu/node_modules/supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/workshopper-adventure-test/node_modules/string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha512-ev2QzSzWPYmy9GuqfIVildA4OdcGLeFZQrq5ys6RtiuF+RQQiZWr8TZNyAcuVXyQRYfEO+MsoB/1BuQVhOJuoQ==", + "dev": true + }, + "node_modules/workshopper-adventure-test/node_modules/workshopper-adventure": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/workshopper-adventure/-/workshopper-adventure-6.1.1.tgz", + "integrity": "sha512-Ny0LfUW4HeU4XlQyYYgqFzQoK39Un4XQSl/D3RUS2gW1BU8FDufnQu9IYVN9DYt6hzM+kaD7EumC7BXHEpPWFw==", + "dev": true, + "dependencies": { + "after": "^0.8.2", + "chalk": "^3.0.0", + "colors-tmpl": "~1.0.0", + "combined-stream-wait-for-it": "^1.1.0", + "commandico": "^2.0.4", + "i18n-core": "^3.0.0", + "latest-version": "^5.1.0", + "msee": "^0.3.5", + "simple-terminal-menu": "^1.1.3", + "split": "^1.0.0", + "string-to-stream": "^3.0.1", + "strip-ansi": "^6.0.0", + "through2": "^3.0.1", + "workshopper-adventure-storage": "^3.0.0" + } + }, + "node_modules/workshopper-adventure/node_modules/chalk": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", + "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "dependencies": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/wrap-ansi/node_modules/ansi-regex": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", + "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/wrap-ansi/node_modules/ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/wrap-ansi/node_modules/color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/wrap-ansi/node_modules/color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "dev": true + }, + "node_modules/wrap-ansi/node_modules/string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "dependencies": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/wrap-ansi/node_modules/strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "dependencies": { + "ansi-regex": "^4.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + }, + "node_modules/xdg-basedir": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/xdg-basedir/-/xdg-basedir-4.0.0.tgz", + "integrity": "sha512-PSNhEJDejZYV7h50BohL09Er9VaIefr2LMAf3OEmpCkjOi34eYyQYAXUTjEQtZJTKcF0E2UKTh+osDLsgNim9Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "engines": { + "node": ">=0.4" + } + }, + "node_modules/y18n": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", + "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", + "dev": true + }, + "node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, + "node_modules/yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "dev": true, + "dependencies": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + } + }, + "node_modules/yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "dev": true, + "dependencies": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "node_modules/yargs-unparser": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.0.tgz", + "integrity": "sha512-W9tKgmSn0DpSatfri0nx52Joq5hVXgeLiqR/5G0sZNDoLZFOr/xjBUDcShCOGNsBnEMNo1KAMBkTej1Hm62HTw==", + "dev": true, + "dependencies": { + "flat": "^4.1.0", + "lodash": "^4.17.15", + "yargs": "^13.3.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yargs/node_modules/ansi-regex": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", + "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/yargs/node_modules/find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "dependencies": { + "locate-path": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yargs/node_modules/locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "dependencies": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yargs/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/yargs/node_modules/p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "dependencies": { + "p-limit": "^2.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yargs/node_modules/path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/yargs/node_modules/string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "dependencies": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yargs/node_modules/strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "dependencies": { + "ansi-regex": "^4.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + } + } +} diff --git a/package.json b/package.json index 3da26116..ed2ca1c7 100644 --- a/package.json +++ b/package.json @@ -1,20 +1,30 @@ { "name": "javascripting", "description": "Learn JavaScript by adventuring around in the terminal.", - "version": "2.0.1", - "repository": { - "url": "git://github.com/sethvincent/javascripting.git" - }, + "version": "2.7.4", "author": "sethvincent", "bin": { - "javascripting": "index.js" + "javascripting": "./bin/javascripting" }, - "preferGlobal": true, "dependencies": { - "cli-md": "^0.1.0", - "colors": "^1.0.3", - "diff": "^1.2.1", - "workshopper-adventure": "git://github.com/martinheidegger/workshopper.git#adventure" + "colors": "1.4.0", + "diff": "^5.1.0", + "workshopper-adventure": "^7.0.0" + }, + "devDependencies": { + "standard": "^17.1.0", + "workshopper-adventure-test": "^1.2.0" + }, + "engines": { + "node": ">=16.20.1" + }, + "license": "MIT", + "main": "./index.js", + "preferGlobal": true, + "repository": { + "url": "https://github.com/workshopper/javascripting" }, - "license": "MIT" + "scripts": { + "test": "standard && workshopper-adventure-test" + } } diff --git a/problems/accessing-array-values/index.js b/problems/accessing-array-values/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/accessing-array-values/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/accessing-array-values/problem.md b/problems/accessing-array-values/problem.md index 70a8e84e..78d7f6f5 100644 --- a/problems/accessing-array-values/problem.md +++ b/problems/accessing-array-values/problem.md @@ -1,7 +1,3 @@ ---- - -# ACCESSING ARRAY VALUES - Array elements can be accessed through index number. Index number starts from zero to array's property length minus one. @@ -10,9 +6,9 @@ Here is an example: ```js - var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] - console.log(pets[0]); +console.log(pets[0]) ``` The above code will print the first element of `pets` array - string `cat`. @@ -24,12 +20,12 @@ Dot notation is invalid. Valid notation: ```js - console.log(pets[0]); +console.log(pets[0]) ``` Invalid notation: ``` - console.log(pets.1); +console.log(pets.1); ``` ## The challenge: @@ -38,7 +34,7 @@ Create a file named `accessing-array-values.js`. In that file, define array `food` : ```js -var food = ['apple', 'pizza', 'pear']; +const food = ['apple', 'pizza', 'pear'] ``` @@ -46,6 +42,6 @@ Use `console.log()` to print the `second` value of array to the terminal. Check to see if your program is correct by running this command: -`javascripting verify accessing-array-values.js` - ---- +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_es.md b/problems/accessing-array-values/problem_es.md index dac29a81..17297941 100644 --- a/problems/accessing-array-values/problem_es.md +++ b/problems/accessing-array-values/problem_es.md @@ -1,17 +1,13 @@ ---- - -# ACCEDIENDO A LOS VALORES DE UN ARRAY - Se puede tener acceso a los elementos de un Array a través del número de índice. -El número de índice comienza en cero y finaliza en el valor de la propiedad longitud (length) del array, restándole uno. +El número de índice comienza en cero y finaliza en el valor de la propiedad longitud (length) del array, restándole uno. A continuación, un ejemplo: ```js - var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] - console.log(pets[0]); +console.log(pets[0]) ``` El código de arriba, imprime el primer elemento del array de `pets` - string `cat` @@ -23,12 +19,12 @@ Notación de punto es inválida. Notación válida: ```js - console.log(pets[0]); +console.log(pets[0]) ``` Notación inválida: ``` - console.log(pets.1); +console.log(pets.1); ``` ## El ejercicio: @@ -37,13 +33,13 @@ Crea un archivo llamado `accediendo-valores-array.js` En ese archivo, define un array llamado `food` : ```js -var food = ['apple', 'pizza', 'pear']; +const food = ['apple', 'pizza', 'pear'] ``` Usa `console.log()` para imprimir el `segundo` valor del array en la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify accediendo-valores-array.js` - ---- +```bash +javascripting verify accediendo-valores-array.js +``` diff --git a/problems/accessing-array-values/problem_fr.md b/problems/accessing-array-values/problem_fr.md new file mode 100644 index 00000000..433fd93b --- /dev/null +++ b/problems/accessing-array-values/problem_fr.md @@ -0,0 +1,44 @@ +On peut accéder aux cases du tableau via leurs index. + +Les index doivent être des nombres allant de zero à la longueur du tableaux moins un. + +Voici un exemple : + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +Le code ci-dessus affichera le premier élément du tableau `pets` - la chaine de caractères `cat`. + +On ne doit accéder aux éléments de tableaux qu'au travers de la notation « crochets » : la notation en point est invalide. + +Notation valide : + +```js +console.log(pets[0]) +``` + +Notation invalide : +``` +console.log(pets.1); +``` + +## Le défi : + +Créez un fichier nommé `acces-valeurs-tableau.js` + +Dans ce fichier, définissez un tableau `food` : +```js +const food = ['apple', 'pizza', 'pear'] +``` + + +Utilisez `console.log()` pour afficher la `deuxième` valeur du tableau dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify acces-valeurs-tableau.js +``` diff --git a/problems/accessing-array-values/problem_it.md b/problems/accessing-array-values/problem_it.md new file mode 100644 index 00000000..44834edf --- /dev/null +++ b/problems/accessing-array-values/problem_it.md @@ -0,0 +1,47 @@ +È possibile accedere agli elementi di un array tramite il loro indice numerico. + +L'indice numerico comincia da zero e arriva al valore della proprietà `length` dell'array meno uno. + +Ecco un esempio: + + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +Il codice precedente stampa il primo elemento dell'array `pets` - la stringa `cat`. + +È necessario accedere agli elementi dell'array soltanto attraverso la notazione con parentesi quadre. + +La notazione puntata non è valida. + +Notazione valida: + +```js +console.log(pets[0]) +``` + +Notazione non valida: +``` +console.log(pets.1); +``` + +## La sfida: + +Crea un file dal nome `accessing-array-values.js`. + +In questo file, definisci l'array `food` : +```js +const food = ['apple', 'pizza', 'pear'] +``` + + +Usa `console.log()` per stampare il `secondo` valore dell'array sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_ja.md b/problems/accessing-array-values/problem_ja.md index ed8867fa..108a21d5 100644 --- a/problems/accessing-array-values/problem_ja.md +++ b/problems/accessing-array-values/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 配列の値にアクセスする - 配列の要素には添え字を使ってアクセスできます。 添え字は `0` から `配列の長さ - 1` までの数です。 @@ -9,9 +5,9 @@ 以下に例を示します... ```js -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] -console.log(pets[0]); +console.log(pets[0]) ``` 上記のコードは配列 `pets` の最初の要素、つまり文字列 `cat` を表示します。 @@ -21,7 +17,7 @@ console.log(pets[0]); 有効な書き方 ```js -console.log(pets[0]); +console.log(pets[0]) ``` ドット表記を使ってもアクセスできません。 @@ -38,7 +34,7 @@ console.log(pets.1); ファイルの中で、次の配列 `food` を定義します。 ```js -var food = ['apple', 'pizza', 'pear']; +const food = ['apple', 'pizza', 'pear'] ``` @@ -46,6 +42,6 @@ var food = ['apple', 'pizza', 'pear']; 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify accessing-array-values.js` - ---- +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_ko.md b/problems/accessing-array-values/problem_ko.md index 1545ed86..991549f5 100644 --- a/problems/accessing-array-values/problem_ko.md +++ b/problems/accessing-array-values/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 배열 값에 접근하기 - 배열 요소는 인덱스 숫자로 접근 할 수 있습니다. 인덱스 숫자는 0에서 시작해 "배열의 프로퍼티 길이 - 1"까지 입니다. @@ -10,9 +6,9 @@ ```js - var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] - console.log(pets[0]); +console.log(pets[0]) ``` 위의 코드는 `pet`의 첫 번째 요소인 `cat` 문자열을 출력할 것입니다. @@ -24,12 +20,12 @@ 유효한 표기법 ```js - console.log(pets[0]); +console.log(pets[0]) ``` 유효하지 않은 표기법 ``` - console.log(pets.1); +console.log(pets.1); ``` ## 도전 과제 @@ -38,7 +34,7 @@ 그 파일에서, `food`라는 배열을 정의합니다. ```js -var food = ['apple', 'pizza', 'pear']; +const food = ['apple', 'pizza', 'pear'] ``` @@ -46,6 +42,6 @@ var food = ['apple', 'pizza', 'pear']; 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify accessing-array-values.js` - ---- +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_nb-no.md b/problems/accessing-array-values/problem_nb-no.md new file mode 100644 index 00000000..c397e133 --- /dev/null +++ b/problems/accessing-array-values/problem_nb-no.md @@ -0,0 +1,45 @@ +Verdiene i et array kan nås ved å bruke et indeksnummer. + +Indeksnummeret starter fra null opp til antallet verdier i arrayet, minus en. + +Her er et eksempel: + +```js +const dyr = ['katt', 'hund', 'rotte'] + +console.log(dyr[0]) +``` + +Koden over skriver ut den første verdien i `dyr` arrayet - strengen `katt`. + +Array verdier kan kun nås ved å bruke klammeparantes. + +Punktum notasjon er ikke gyldig. + +Gyldig: + +```js +console.log(dyr[0]) +``` + +Ugyldig: +``` +console.log(dyr.1); +``` + +## Oppgaven: + +Lag en fil som heter `accessing-array-values.js`. + +Definer et array `food` i den filen: +```js +const food = ['apple', 'pizza', 'pear'] +``` + +Bruk `console.log()` til å skrive ut den `andre` verdien av det arrayet til skjermen. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_nl.md b/problems/accessing-array-values/problem_nl.md new file mode 100755 index 00000000..13cc1050 --- /dev/null +++ b/problems/accessing-array-values/problem_nl.md @@ -0,0 +1,46 @@ +Waarden in een Array kun je opvragen met een index numner. + +Het index nummer begint bij nul en loopt tot de *.length* eigenschap van de array min één. + +Hier is een voorbeeld: + + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +De bovenstaande code print het eerste element van de `pets` array - dat is de string `cat`. + +Array elementen kun je benaderen via blokhaken [] + +Het gebruik van een punt is niet juist. + +Juiste notatie: + +```js +console.log(pets[0]) +``` + +Onjuiste notatie: +``` +console.log(pets.1); +``` + +## De uitdaging: + +Maak een nieuw bestand met de naam `accessing-array-values.js`. + +Definieer in dit bestand een array genaamd `food` : +```js +const food = ['apple', 'pizza', 'pear'] +``` + +Gebruik `console.log()` om de `tweede` waarde van de array naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_pt-br.md b/problems/accessing-array-values/problem_pt-br.md new file mode 100644 index 00000000..d9881ec2 --- /dev/null +++ b/problems/accessing-array-values/problem_pt-br.md @@ -0,0 +1,47 @@ +Podemos acessar elementos de um array através de um número que representa sua posição, conhecido como índice. + +O valor do índice inicia com 0 e vai até o valor que representa o tamanho do array menos 1. + +Aqui está um exemplo: + + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +O código acima imprime o primeiro elemento do array `pets` - a string `cat`. + +Os elementos do array devem ser acessados através do uso do valor do índice entre colchetes. + +Utilizar ponto para acessar o elemento não é válido. + +Uso válido: + +```js +console.log(pets[0]) +``` + +Uso invalido: +``` +console.log(pets.1); +``` + +## Desafio: + +Crie um arquivo chamado `accessing-array-values.js`. + +Neste arquivo, defina o array `food` : +```js +const food = ['apple', 'pizza', 'pear'] +``` + + +Use o `console.log()` para imprimir o segundo valor do array no terminal. + +Verifique se o seu programa está correto executando este comando: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_ru.md b/problems/accessing-array-values/problem_ru.md new file mode 100644 index 00000000..9b2c31a6 --- /dev/null +++ b/problems/accessing-array-values/problem_ru.md @@ -0,0 +1,47 @@ +Элементы массива могут быть получены при помощи числового индекса. + +Индекс может иметь значение от нуля до величины свойства `length` массива, минус единица. + +Например: + + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +Приведённый выше код должен вывести первый элемент массива `pets` -- строку `cat`. + +Доступ к элементам массива может осуществляться только с помощью литерала массива (квадратные скобки). + +Обращение через точку является неверным. + +Правильная запись: + +```js +console.log(pets[0]) +``` + +Неправильная запись: +``` + console.log(pets.1); +``` + +## Условие задачи: + +Создайте файл с названием `accessing-array-values.js`. + +В этом файле объявите массив `food` : +```js +const food = ['apple', 'pizza', 'pear'] +``` + + +Воспользуйтесь командой `console.log()`, чтобы вывести значение `второго` элемента массива в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_uk.md b/problems/accessing-array-values/problem_uk.md new file mode 100644 index 00000000..c6e11cd6 --- /dev/null +++ b/problems/accessing-array-values/problem_uk.md @@ -0,0 +1,45 @@ +Доступ до елементів масиву можна отримати з допомогою індексу. + +Індексом може бути число від 0 до розміру масиву, зменшеного на одиницю (n-1). + +Приклад: + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +Код вище виведе перший елемент масиву `pets` - рядок `cat`. + +Доступ до елементів масиву можна отримати лише з допомогою квадратних дужок []. + +Доступ з допомогою крапки є неправильний. + +Правильний запис: + +```js +console.log(pets[0]) +``` + +Неправильний запис: +```js +console.log(pets.1) +``` + +## Завдання: + +Створити файл `accessing-array-values.js`. + +У цьому файлі створити масив 'food' : +```js +const food = ['apple', 'pizza', 'pear'] +``` + +Використайте `console.log()`, щоб надрукувати 'другий' елемент масиву в терміналі. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_zh-cn.md b/problems/accessing-array-values/problem_zh-cn.md index 9118fb03..ccbe8719 100644 --- a/problems/accessing-array-values/problem_zh-cn.md +++ b/problems/accessing-array-values/problem_zh-cn.md @@ -1,18 +1,13 @@ ---- - -# 访问数组中的值 - 数组中的元素可以通过一个索引值来访问。 索引值就是一个整数,从 0 开始一直到数组的长度减一。 下面是一个例子: - ```js - var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] - console.log(pets[0]); +console.log(pets[0]) ``` 上面的代码将打印出 `pets` 数组的第一个元素,也就是字符串 `cat`。 @@ -24,12 +19,12 @@ 这是一个正确的例子: ```js - console.log(pets[0]); +console.log(pets[0]) ``` 下面的用法是错误的: ``` - console.log(pets.1); +console.log(pets.1); ``` ## 挑战: @@ -38,13 +33,13 @@ 在文件中定义一个数组 `food`: ```js -var food = ['apple', 'pizza', 'pear']; +const food = ['apple', 'pizza', 'pear'] ``` 使用 `console.log()` 打印数组的第二个值到终端。 运行下面的命令来检查你的程序是否正确: -`javascripting verify accessing-array-values.js` - ---- +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/problem_zh-tw.md b/problems/accessing-array-values/problem_zh-tw.md new file mode 100644 index 00000000..f6511ffb --- /dev/null +++ b/problems/accessing-array-values/problem_zh-tw.md @@ -0,0 +1,45 @@ +陣列中的元素可以通過一個索引值來訪問。 + +索引值就是一個整數,從 0 開始一直到陣列的長度減一。 + +下面是一個例子: + +```js +const pets = ['cat', 'dog', 'rat'] + +console.log(pets[0]) +``` + +上面的程式碼將印出 `pets` 陣列的第一個元素,也就是字串 `cat`。 + +陣列元素必須通過中括號來訪問。 + +英文句號的方式將會導致錯誤。 + +這是一個正確的例子: + +```js +console.log(pets[0]) +``` + +下面的用法是錯誤的: +``` +console.log(pets.1); +``` + +## 挑戰: + +建立一個名為 `accessing-array-values.js` 的檔案。 + +在該檔案中定義一個陣列 `food`: +```js +const food = ['apple', 'pizza', 'pear'] +``` + +使用 `console.log()` 印出陣列中的 `第二個` 值。 + +執行下面的命令來檢查你的程式是否正確: + +```bash +javascripting verify accessing-array-values.js +``` diff --git a/problems/accessing-array-values/solution_es.md b/problems/accessing-array-values/solution_es.md index 0d608408..0f2594e5 100644 --- a/problems/accessing-array-values/solution_es.md +++ b/problems/accessing-array-values/solution_es.md @@ -6,6 +6,6 @@ Buen trabajo, lograste acceder a ese elemento del array. En el siguiente ejercicio trabajaremos un ejemplo de bucles usando arrays. -Corre `javascripting` en la consola para seleccionar el siguiente ejercicio. +Ejecuta `javascripting` en la consola para seleccionar el siguiente ejercicio. ---- \ No newline at end of file +--- diff --git a/problems/accessing-array-values/solution_fr.md b/problems/accessing-array-values/solution_fr.md new file mode 100644 index 00000000..1450ab10 --- /dev/null +++ b/problems/accessing-array-values/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# DEUXIÈME ÉLÉMENT DU TABLEAU AFFICHÉ ! + +Vous avez réussi à accéder au second élément du tableau. + +Dans le défi suivant nous allons travailler sur un exemple de boucle de parcours de tableaux. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/accessing-array-values/solution_it.md b/problems/accessing-array-values/solution_it.md new file mode 100644 index 00000000..a7d3d54b --- /dev/null +++ b/problems/accessing-array-values/solution_it.md @@ -0,0 +1,11 @@ +--- + +# HAI STAMPATO IL SECONDO ELEMENTO DELL'ARRAY! + +Ottimo lavoro nell'accedere all'elemento dell'array. + +Nella prossima sfida lavoreremo su un esempio di iterazione sugli elementi di un array. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/accessing-array-values/solution_nb-no.md b/problems/accessing-array-values/solution_nb-no.md new file mode 100644 index 00000000..ed796ba1 --- /dev/null +++ b/problems/accessing-array-values/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# DEN ANDRE VERDIEN AV ARRAYET SKREVET UT! + +Godt jobba med å bruke den verdien i arrayet. + +I den neste oppgaven skal vi jobbe med et eksempel på å bruke løkker på arrayer. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- \ No newline at end of file diff --git a/problems/accessing-array-values/solution_nl.md b/problems/accessing-array-values/solution_nl.md new file mode 100644 index 00000000..23b3936a --- /dev/null +++ b/problems/accessing-array-values/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# TWEEDE ELEMENT VAN DE ARRAY GEPRINT! + +Goed gedaan om toegang te krijgen tot dat element van de array. + +In de volgende uitdaging gaan we loopen door arrays + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- \ No newline at end of file diff --git a/problems/accessing-array-values/solution_pt-br.md b/problems/accessing-array-values/solution_pt-br.md new file mode 100644 index 00000000..7c355b3b --- /dev/null +++ b/problems/accessing-array-values/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# VOCÊ IMPRIMIU O SEGUNDO ELEMENTO DO ARRAY! + +Você realizou um bom trabalho ao acessar aquele elemento do array. + +No próximo desafio vamos ver como fazer um loop pelos elementos do array. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- \ No newline at end of file diff --git a/problems/accessing-array-values/solution_ru.md b/problems/accessing-array-values/solution_ru.md new file mode 100644 index 00000000..50997a32 --- /dev/null +++ b/problems/accessing-array-values/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ОТОБРАЖЕН ВТОРОЙ ЭЛЕМЕНТ МАССИВА! + +Отличная работа, вам удалось получить элемент массива. + +В следующей задаче мы будем работать с примером обхода массива в цикле. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/accessing-array-values/solution_uk.md b/problems/accessing-array-values/solution_uk.md new file mode 100644 index 00000000..34a0203b --- /dev/null +++ b/problems/accessing-array-values/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ДРУГИЙ ЕЛЕМЕНТ МАСИВУ ВИВЕДЕНО! + +Гарна робота! + +В наступному завданні ми розглянемо приклад проходження по елементах масиву. + +Запустіть `javascripting` в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/accessing-array-values/solution_zh-tw.md b/problems/accessing-array-values/solution_zh-tw.md new file mode 100644 index 00000000..27cc4bb5 --- /dev/null +++ b/problems/accessing-array-values/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 陣列的第二個值已經被印出來了! + +做得好!你已經學會如何存取陣列中的值。 + +下一個挑戰中我們將看到如何用迴圈依次存取陣列中的值。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/array-filtering/index.js b/problems/array-filtering/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/array-filtering/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/array-filtering/problem.md b/problems/array-filtering/problem.md index 18da0a87..971e583f 100644 --- a/problems/array-filtering/problem.md +++ b/problems/array-filtering/problem.md @@ -1,7 +1,3 @@ ---- - -# ARRAY FILTERING - There are many ways to manipulate arrays. One common task is filtering arrays to only contain certain values. @@ -11,11 +7,11 @@ For this we can use the `.filter()` method. Here is an example: ```js -var pets = ['cat', 'dog', 'elephant']; +const pets = ['cat', 'dog', 'elephant'] -var filtered = pets.filter(function (pet) { - return (pet !== 'elephant'); -}); +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) ``` The `filtered` variable will now only contain `cat` and `dog`. @@ -27,7 +23,7 @@ Create a file named `array-filtering.js`. In that file, define a variable named `numbers` that references this array: ```js -[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] ``` Like above, define a variable named `filtered` that references the result of `numbers.filter()`. @@ -36,14 +32,14 @@ The function that you pass to the `.filter()` method will look something like th ```js function evenNumbers (number) { - return number % 2 === 0; + return number % 2 === 0 } ``` -Use `console.log()` to print the `filtered` array to the terminal. +Pay close attention to the syntax used throughout your solution. Use `console.log()` to print the `filtered` array to the terminal. Check to see if your program is correct by running this command: -`javascripting verify array-filtering.js` - ---- +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_es.md b/problems/array-filtering/problem_es.md index cbfab094..2382a3b9 100644 --- a/problems/array-filtering/problem_es.md +++ b/problems/array-filtering/problem_es.md @@ -13,11 +13,11 @@ Para esto podemos utilizar el método `.filter`. Por ejemplo: ```js -var pets = ['cat', 'dog', 'elephant']; +const pets = ['cat', 'dog', 'elephant'] -var filtered = pets.filter(function (pet) { - return (pet !== 'elephant'); -}); +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) ``` La variable `filtered` será igual a un array que contiene solo `cat` y `dog`. @@ -29,7 +29,7 @@ Crea un archivo llamado `filtrado-de-arrays.js`. En ese archivo, define una variable llamada `numbers` que referencie al siguiente array: ```js -[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] ``` Luego, define una variable llamada `filtered` que referencie el resultado de `numbers.filter()`. @@ -38,7 +38,7 @@ La función que recibe `.filter()` será algo cómo lo siguiente: ```js function evenNumbers (number) { - return number % 2 === 0; + return number % 2 === 0 } ``` @@ -46,6 +46,6 @@ Utiliza `console.log()` para imprimir el array filtrado a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify filtrado-de-arrays.js` - ---- +``` +javascripting verify filtrado-de-arrays.js +``` diff --git a/problems/array-filtering/problem_fr.md b/problems/array-filtering/problem_fr.md new file mode 100644 index 00000000..cdf76aba --- /dev/null +++ b/problems/array-filtering/problem_fr.md @@ -0,0 +1,45 @@ +Il y a beaucoup de manières de manipuler les tableaux. + +Une tâche commune est de filtrer les tableaux pour ne garder que certaines valeurs. + +Pour cela nous pouvons utiliser la méthode `.filter()`. + +Voici un exemple : + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +La variable `filtered` ne va contenir que `cat` et `dog`. + +## Le défi : + +Créer un fichier nommé `filtrage-de-tableau.js`. + +Dans ce fichier, définissez une variable nommée `numbers` qui contient ce tableau : + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Comme ci-dessus, définissez une variable nommée `filtered` qui contient le résultat de `numbers.filter()`. + +La fonction que vous passerez à la méthode `.filter()` va ressembler à ça : + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Utilisez `console.log()` pour afficher le tableau `filtered` dans le terminal. + +Vérifiez que votre programme soit correct en exécutant la commande : + +```bash +javascripting verify filtrage-de-tableau.js +``` diff --git a/problems/array-filtering/problem_it.md b/problems/array-filtering/problem_it.md new file mode 100644 index 00000000..d0cc1f65 --- /dev/null +++ b/problems/array-filtering/problem_it.md @@ -0,0 +1,45 @@ +Esistono parecchie maniere di manipolare gli array. + +Un compito comune è filtrare gli array perché contengano soltanto i valori desiderati. + +Per fare ciò possiamo utilizzare il metodo `.filter()`. + +Ecco un esempio: + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +La variabile `filtered` conterrà soltanto `cat` e `dog`. + +## La sfida: + +Crea un file dal nome `array-filtering.js`. + +In questo file, definisci una variabile chiamata `numbers` che fa riferimento a questo array: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Come sopra, definisci una variabile chiamata `filtered` che fa riferimento al risultato di `numbers.filter()`. + +La funzione che passerai al metodo `.filter()` dovrà apparire come segue: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Usa `console.log()` per stampare l'array `filtered` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_ja.md b/problems/array-filtering/problem_ja.md index db3cd4c0..6a203764 100644 --- a/problems/array-filtering/problem_ja.md +++ b/problems/array-filtering/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 配列のフィルター - 配列にはいろいろな操作方法があります。 よくやる処理に、配列にフィルターをかけて、特定の値を取り出す。というものがあります。 @@ -11,11 +7,11 @@ たとえば... ```js -var pets = ['cat', 'dog', 'elephant']; +const pets = ['cat', 'dog', 'elephant'] -var filtered = pets.filter(function (pet) { - return (pet !== 'elephant'); -}); +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) ``` `フィルターした` 配列の中には `cat` と `dog` だけが残ります。 @@ -28,7 +24,7 @@ var filtered = pets.filter(function (pet) { ファイルの中で、 次の配列を表す、変数 `numbers` を定義しましょう。 ```js -[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] ``` 同様に、 `numbers.filter()` の実行結果を表す、変数 `filtered` を定義しましょう。 @@ -37,7 +33,7 @@ var filtered = pets.filter(function (pet) { ```js function evenNumbers (number) { - return number % 2 === 0; + return number % 2 === 0 } ``` @@ -45,6 +41,6 @@ function evenNumbers (number) { 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify array-filtering.js` - ---- +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_ko.md b/problems/array-filtering/problem_ko.md index 83655399..d47157fc 100644 --- a/problems/array-filtering/problem_ko.md +++ b/problems/array-filtering/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 배열 필터 - 배열을 조작하는 방법은 여러가지가 있습니다. 대표적인 사용법으로 특정 값만 가진 배열로 필터링하는 것이 있습니다. @@ -11,11 +7,11 @@ 여기에 예제가 있습니다. ```js -var pets = ['cat', 'dog', 'elephant']; +const pets = ['cat', 'dog', 'elephant'] -var filtered = pets.filter(function (pet) { - return (pet !== 'elephant'); -}); +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) ``` `filtered` 변수는 이제 `cat`과 `dog`만 가지고 있습니다. @@ -27,7 +23,7 @@ var filtered = pets.filter(function (pet) { 이 파일에 밑의 배열을 참조하는 `numbers`라는 변수를 정의합니다. ```js -[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] ``` 위에 있는 것처럼, `numbers.filter()`의 결과를 참조하는 `filtered`라는 변수를 선언합니다. @@ -36,7 +32,7 @@ var filtered = pets.filter(function (pet) { ```js function evenNumbers (number) { - return number % 2 === 0; + return number % 2 === 0 } ``` @@ -44,6 +40,6 @@ function evenNumbers (number) { 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify array-filtering.js` - ---- +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_nb-no.md b/problems/array-filtering/problem_nb-no.md new file mode 100644 index 00000000..1bae82a8 --- /dev/null +++ b/problems/array-filtering/problem_nb-no.md @@ -0,0 +1,44 @@ +Det finnes mange måter å manipulere arrayer på. + +Noe man ofte gjør er å filtrere et array til å kun inneholde noen ønskede verdier. + +For det kan vi bruke `.filter()` metoden. + +Her er et eksempel: + +```js +const dyr = ['katt', 'hund', 'elefant'] + +const filtrert = dyr.filter(function (ettDyr) { + return (ettDyr !== 'elefant') +}) +``` +`filtrert` variablen vil nå kun inneholde `katt` og `hund`. + +## Oppgaven: + +Lag en fil som heter `array-filtering.js`. + +Definer en variabel med navnet `numbers` i den filen som referer dette arrayet: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Som i eksemplet over, definer en variabel med navnet `filtered` som refererer resultatet av `numbers.filter()`. + +Funksjonen du gir til `.filter()` metoden skal se slik ut: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Bruk `console.log()` til å skrive ut `filtered` arrayet til skjermen. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_nl.md b/problems/array-filtering/problem_nl.md new file mode 100755 index 00000000..1c3e2004 --- /dev/null +++ b/problems/array-filtering/problem_nl.md @@ -0,0 +1,45 @@ +Er zijn veel manieren om arrays aan te passen + +Een veelvookomende handeling is het filteren van arrays zodat alleen bepaalde waarden overblijven. + +Hiervoor kun je de `.filter()` method gebruiken. + +Hier is een voorbeeld: + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +De `filtered` variabele bevat nu alleen `cat` en `dog`. + +## De uitdaging + +Maak een nieuw bestand met de naam `array-filtering.js`. + +Definieer in dit bestand een variabele met de naam `numbers` die verwijst naar deze array: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Zoals bovenaan is voorgedaan, maak nu een variabele genaamd `filtered` die verwijst naar het resultaat van `numbers.filter()`. + +De functie die je aan de `.filter()` method geeft ziet er zo uit: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Let goed op de syntax die gebruikt wordt in deze uitdaging. Gebruik `console.log()` om de `filtered` array naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_pt-br.md b/problems/array-filtering/problem_pt-br.md new file mode 100644 index 00000000..d112e183 --- /dev/null +++ b/problems/array-filtering/problem_pt-br.md @@ -0,0 +1,45 @@ +Existem muitas formas de manipular arrays. + +Uma tarefa comum é filtrar um array para que ele tenha somente alguns valores. + +Para isso podemos usar o método `.filter()`. + +Aqui está um exemplo: + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +A variável `filtered` irá conter apenas `cat` e `dog`. + +## Desafio: + +Crie um arquivo chamado `array-filtering.js`. + +Neste arquivo, defina uma variável chamada `numbers` que referencia este array: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Como acima, defina uma variavel chamada `filtered` com referência ao resultado de `numbers.filter()`. + +A função que você passa para o método `.filter()` será igual essa: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Use o `console.log()` para imprimir o array `filtered` no terminal. + +Verifique se o seu programa está correto executando este comando: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_ru.md b/problems/array-filtering/problem_ru.md new file mode 100644 index 00000000..6d33b5f1 --- /dev/null +++ b/problems/array-filtering/problem_ru.md @@ -0,0 +1,45 @@ +Существует множество способов манипуляции массивами. + +Одной из распространённых задач является фильтрация массива, позволяющая получить массив с определёнными значениями. + +Для этого мы будем использовать метод `.filter()`. + +Например: + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +Переменная `filtered` теперь будет содержать массив с элементами `cat` и `dog`. + +## Условие задачи: + +Создайте файл `array-filtering.js`. + +В этом файле требуется объявить переменную `numbers`, которой должен быть присвоен следующий массив: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Как было показано выше, объявите переменную `filtered` и присвойте ей результат выполнения `numbers.filter()`. + +Функция, которая должна быть передана в виде аргумента методу `.filter()`, будет выглядеть следующим образом: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Воспользуйтесь командой `console.log()`, чтобы вывести массив `filtered` в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_uk.md b/problems/array-filtering/problem_uk.md new file mode 100644 index 00000000..01666ce6 --- /dev/null +++ b/problems/array-filtering/problem_uk.md @@ -0,0 +1,45 @@ +Є багато способів маніпуляції масивами. + +Часто постає потреба відфільтрувати масиви за певною умовою. + +Для цього ми можемо використати метод `.filter()`. + +Приклад: + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +Змінна `filtered` буде містили лише елементи `cat` та `dog`. + +## Завдання: + +Створити файл 'array-filtering.js'. + +У цьому файлі, створіть змінну 'numbers', що міститиме такий масив: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +Як у прикладі вище, оголосіть змінну `filtered`, що міститиме результат виконання `numbers.filter()`. + +Функція, яку ви маєте передати у метод `.filter()` буде виглядати приблизно так: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +Скористайтесь `console.log()`, щоб вивести масив `filtered` в термінал. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_zh-cn.md b/problems/array-filtering/problem_zh-cn.md index 0b5eab4d..75b7bd2b 100644 --- a/problems/array-filtering/problem_zh-cn.md +++ b/problems/array-filtering/problem_zh-cn.md @@ -1,7 +1,3 @@ ---- - -# 数组过滤 - 有许多种方法可以对数组进行操作。 一个常见的任务是过滤一个数组使之仅包含特定的值。 @@ -11,11 +7,11 @@ 下面是一个例子: ```js -var pets = ['cat', 'dog', 'elephant']; +const pets = ['cat', 'dog', 'elephant'] -var filtered = pets.filter(function (pet) { - return (pet !== 'elephant'); -}); +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) ``` 变量 `filtered` 现在仅包含 `cat` 和 `dog`。 @@ -27,7 +23,7 @@ var filtered = pets.filter(function (pet) { 在文件中,定义一个名为 `numbers` 的变量,并赋予下面的值: ```js -[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] ``` 像上面的例子那样,定义一个 `filtered` 变量,使它引用 `numbers.filter()` 的结果。 @@ -36,7 +32,7 @@ var filtered = pets.filter(function (pet) { ```js function evenNumbers (number) { - return number % 2 === 0; + return number % 2 === 0 } ``` @@ -44,6 +40,6 @@ function evenNumbers (number) { 运行下面的命令来检查你的程序是否正确: -`javascripting verify array-filtering.js` - ---- +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/problem_zh-tw.md b/problems/array-filtering/problem_zh-tw.md new file mode 100644 index 00000000..fdb79db3 --- /dev/null +++ b/problems/array-filtering/problem_zh-tw.md @@ -0,0 +1,45 @@ +有許多種方法可以對陣列進行操作。 + +一個常見的任務是過濾一個陣列使之僅包含特定的值。 + +使用 `.filter()` 方法可以達到這個目的。 + +下面是一個例子: + +```js +const pets = ['cat', 'dog', 'elephant'] + +const filtered = pets.filter(function (pet) { + return (pet !== 'elephant') +}) +``` + +變數 `filtered` 現在僅包含 `cat` 和 `dog`。 + +## 挑戰: + +建立一個名為 `array-filtering.js` 的檔案。 + +在該檔案中,定義一個名為 `numbers` 的變數,並賦予下面的值: + +```js +[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +``` + +像上面的例子那樣,定義一個 `filtered` 變數,使它引用 `numbers.filter()` 的結果。 + +傳遞給 `.filter()` 方法的函式應該像下面這樣: + +```js +function evenNumbers (number) { + return number % 2 === 0 +} +``` + +使用 `console.log()` 印出變數 `filtered` 陣列到終端機上。 + +執行下面的命令來檢查你撰寫的程式是否正確: + +```bash +javascripting verify array-filtering.js +``` diff --git a/problems/array-filtering/solution_es.md b/problems/array-filtering/solution_es.md index 4b7ea0e5..c69541c1 100644 --- a/problems/array-filtering/solution_es.md +++ b/problems/array-filtering/solution_es.md @@ -4,7 +4,7 @@ Buen trabajo filtrando ese array. -En el siguiente ejercicio estarmos trabajando con un ejemplo de cómo recorrer arrays. +En el siguiente ejercicio estaremos trabajando con un ejemplo de cómo recorrer arrays. Ejecuta `javascripting` en la consola para seleccionar el siguiente ejercicio. diff --git a/problems/array-filtering/solution_fr.md b/problems/array-filtering/solution_fr.md new file mode 100644 index 00000000..0069ee6d --- /dev/null +++ b/problems/array-filtering/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# FILTRÉ ! + +Vous avez réussi à filtrer le tableau. + +Dans le défi suivant nous allons travailler sur un exemple d'accès aux valeurs d'un tableau. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/array-filtering/solution_it.md b/problems/array-filtering/solution_it.md new file mode 100644 index 00000000..e3ff93ca --- /dev/null +++ b/problems/array-filtering/solution_it.md @@ -0,0 +1,11 @@ +--- + +# FILTRATO! + +Ottimo lavoro nel filtrare l'array. + +Nella prossima sfida lavoreremo su un esempio di accesso ai valori di un array. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/array-filtering/solution_nb-no.md b/problems/array-filtering/solution_nb-no.md new file mode 100644 index 00000000..50524e4f --- /dev/null +++ b/problems/array-filtering/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# FILTRERT! + +Godt jobba med å filtrere det arrayet. + +I den neste oppgaven skal vi jobbe med å lese verdiene i et array. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/array-filtering/solution_nl.md b/problems/array-filtering/solution_nl.md new file mode 100644 index 00000000..ba2a920f --- /dev/null +++ b/problems/array-filtering/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# GEFILTERD! + +Goed bezig met het filteren van die array! + +In de volgende uitdaging gaan werken met code die waarden uit een array haalt. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/array-filtering/solution_pt-br.md b/problems/array-filtering/solution_pt-br.md new file mode 100644 index 00000000..66a5cdd1 --- /dev/null +++ b/problems/array-filtering/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# FILTRADO! + +Você fez um bom trabalho ao filtrar aquele array. + +No próximo desafio vamos ver como acessar os valores de um array. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/array-filtering/solution_ru.md b/problems/array-filtering/solution_ru.md new file mode 100644 index 00000000..fcf1afce --- /dev/null +++ b/problems/array-filtering/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ОТФИЛЬТРОВАНО! + +Отличная работа, вам удалось отфильтровать массив. + +В следующей задаче мы познакомимся с примером обращения к элементу массива. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/array-filtering/solution_uk.md b/problems/array-filtering/solution_uk.md new file mode 100644 index 00000000..2461c0d8 --- /dev/null +++ b/problems/array-filtering/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# Відфільтровано! + +Добре зроблено! + +В наступному завданні ми розглянемо як отримати доступ до елементів масиву. + +Запустіть `javascripting` в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/array-filtering/solution_zh-tw.md b/problems/array-filtering/solution_zh-tw.md new file mode 100644 index 00000000..b6ada6cb --- /dev/null +++ b/problems/array-filtering/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 陣列已經被過濾了! + +做得好。 + +下一個挑戰中我們將學習如何存取陣列中的值。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/arrays/index.js b/problems/arrays/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/arrays/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/arrays/problem.md b/problems/arrays/problem.md index 5d81cec8..1aa44475 100644 --- a/problems/arrays/problem.md +++ b/problems/arrays/problem.md @@ -1,11 +1,7 @@ ---- - -# ARRAYS - An array is a list of values. Here's an example: ```js -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] ``` ### The challenge: @@ -18,6 +14,6 @@ Use `console.log()` to print the `pizzaToppings` array to the terminal. Check to see if your program is correct by running this command: -`javascripting verify arrays.js` - ---- +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_es.md b/problems/arrays/problem_es.md index e02075f7..08717f60 100644 --- a/problems/arrays/problem_es.md +++ b/problems/arrays/problem_es.md @@ -1,11 +1,7 @@ ---- - -# ARRAYS - Un array es una lista ordenada de elementos. Por ejemplo: ```js -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] ``` ### El ejercicio: @@ -14,10 +10,11 @@ Crea un archivo llamado `arrays.js` En ese archivo define una variable llamada `pizzaToppings` que referencie a un array el cual contenga los siguientes elementos (en el siguiente orden): `tomato sauce, cheese, pepperoni`. -Utiliza `console.log()` para imprimir la variable `condimentos` a la terminal. +Utiliza `console.log()` para imprimir la variable `pizzaToppings` a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente commando: -`javascripting verify arrays.js` +```bash +javascripting verify arrays.js +``` ---- diff --git a/problems/arrays/problem_fr.md b/problems/arrays/problem_fr.md new file mode 100644 index 00000000..ab58b092 --- /dev/null +++ b/problems/arrays/problem_fr.md @@ -0,0 +1,19 @@ +Un tableau est une liste de valeurs. Voici un exemple : + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### Le défi : + +Créer un fichier nommé `tableaux.js`. + +Dans ce fichier, définissez une variable nommée `pizzaToppings` qui contient un tableau composé de trois chaînes de caractères dans cet ordre : `tomato sauce, cheese, pepperoni`. + +Utilisez `console.log()` pour afficher le tableau `pizzaToppings` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify tableaux.js +``` diff --git a/problems/arrays/problem_it.md b/problems/arrays/problem_it.md new file mode 100644 index 00000000..0cb896c6 --- /dev/null +++ b/problems/arrays/problem_it.md @@ -0,0 +1,19 @@ +Un array è una lista di valori. Ecco un esempio: + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### La sfida: + +Crea un file dal nome `arrays.js`. + +In questo file, definisci una variabile dal nome `pizzaToppings` che fa riferimento ad un array contenente tre stringhe in quest'ordine: `tomato sauce, cheese, pepperoni`. + +Usa `console.log()` per stampare l'array `pizzaToppings` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_ja.md b/problems/arrays/problem_ja.md index 03a00aec..344845e7 100644 --- a/problems/arrays/problem_ja.md +++ b/problems/arrays/problem_ja.md @@ -1,17 +1,13 @@ ---- - -# 配列 - 配列は、値のリストです。たとえば、こう... ```js -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] ``` ## やってみよう `arrays.js` ファイルを作りましょう。 - + ファイルの中で、配列を表す変数 `pizzaToppings` を定義してください。配列は次の3つの文字列変数を順番通りに含みます... `tomato sauce, cheese, pepperoni` @@ -21,6 +17,7 @@ var pets = ['cat', 'dog', 'rat']; 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify arrays.js` +```bash +javascripting verify arrays.js +``` ---- diff --git a/problems/arrays/problem_ko.md b/problems/arrays/problem_ko.md index f6ac1820..60f4edeb 100644 --- a/problems/arrays/problem_ko.md +++ b/problems/arrays/problem_ko.md @@ -1,11 +1,7 @@ ---- - -# 배열 - 배열은 값의 목록입니다. 예를 들면 다음과 같습니다. ```js -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] ``` ### 도전 과제 @@ -18,6 +14,7 @@ var pets = ['cat', 'dog', 'rat']; 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify arrays.js` +```bash +javascripting verify arrays.js +``` ---- diff --git a/problems/arrays/problem_nb-no.md b/problems/arrays/problem_nb-no.md new file mode 100644 index 00000000..8a1bc5f2 --- /dev/null +++ b/problems/arrays/problem_nb-no.md @@ -0,0 +1,19 @@ +Et array er en liste av verdier. Her er et eksempel: + +```js +const dyr = ['katt', 'hund', 'rotte'] +``` + +### Oppgaven: + +Lag en fil som heter `arrays.js`. + +Definer en variabel med navnet `pizzaToppings` som refererer et array som inneholder tre strenger i følgende rekkefølge: `tomato sauce, cheese, pepperoni` + +Bruk `console.log()` til å skrive ut `pizzaToppings` arrayet til skjermen. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_nl.md b/problems/arrays/problem_nl.md new file mode 100755 index 00000000..dac73115 --- /dev/null +++ b/problems/arrays/problem_nl.md @@ -0,0 +1,19 @@ +Een array is een lijst met waarden. Hier is een voorbeeld: + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### De uitdaging: + +Maak een nieuw bestand met de naam `arrays.js`. + +Definieer in het bestand een variabele met de naam `pizzaToppings` die verwijst naar een array met drie strings in deze volgorde: `tomato sauce, cheese, pepperoni`. + +Gebruik `console.log()` om de `pizzaToppings` array naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_pt-br.md b/problems/arrays/problem_pt-br.md new file mode 100644 index 00000000..ba264ecf --- /dev/null +++ b/problems/arrays/problem_pt-br.md @@ -0,0 +1,19 @@ +Um array é uma lista de valores. Aqui está um exemplo: + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### Desafio: + +Crie um arquivo chamado `arrays.js`. + +No arquivo criado defina uma variável chamada `pizzaToppings` que referencia um array com três strings nesta ordem: `tomato sauce, cheese, pepperoni`. + +Use o `console.log()` para imprimir o array `pizzaToppings` no terminal. + +Verifique se o seu programa está correto executando este comando: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_ru.md b/problems/arrays/problem_ru.md new file mode 100644 index 00000000..9d345bdb --- /dev/null +++ b/problems/arrays/problem_ru.md @@ -0,0 +1,19 @@ +Массив -- это набор значений. Например: + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### Условие задачи: + +Создайте файл `arrays.js`. + +В этом файле требуется объявить переменную `pizzaToppings`, которой должен быть присвоен массив, состоящий из строк в таком порядке: `tomato sauce, cheese, pepperoni`. + +Воспользуйтесь командой `console.log()`, чтобы вывести массив `pizzaToppings` в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_uk.md b/problems/arrays/problem_uk.md new file mode 100644 index 00000000..d101ef6b --- /dev/null +++ b/problems/arrays/problem_uk.md @@ -0,0 +1,19 @@ +Масивами називають значень. Наприклад: + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### Завдання: + +Створіть файл `arrays.js`. + +У цьому файлі оголосіть змінну `pizzaToppings`, що міститиме масив, який має складатись із трьох елементів в такому порядку: 'tomato sauce, cheese, pepperoni'. + +Скористайтесь `console.log()`, щоб вивести масив `pizzaToppings` в терміналі. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_zh-cn.md b/problems/arrays/problem_zh-cn.md index f49be3ef..38226ddc 100644 --- a/problems/arrays/problem_zh-cn.md +++ b/problems/arrays/problem_zh-cn.md @@ -1,11 +1,7 @@ ---- - -# 数组 - 数组就是由一组值构成的列表。下面是一个例子: ```js -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] ``` ### 挑战: @@ -18,6 +14,6 @@ var pets = ['cat', 'dog', 'rat']; 运行下面的命令检查你的程序是否正确: -`javascripting verify arrays.js` - ---- +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/problem_zh-tw.md b/problems/arrays/problem_zh-tw.md new file mode 100644 index 00000000..1696ee8c --- /dev/null +++ b/problems/arrays/problem_zh-tw.md @@ -0,0 +1,19 @@ +陣列就是由一組值構成的列表。下面是一個例子: + +```js +const pets = ['cat', 'dog', 'rat'] +``` + +### 挑戰: + +建立一個名為 `arrays.js` 的檔案。 + +在該檔案中定義一個名為 `pizzaToppings` 的變數,其值依照順序為包含了 `tomato sauce, cheese, pepperoni` 這三個字串的陣列。 + +使用 `console.log()` 將 `pizzaToppings` 陣列印出來。 + +執行下面的命令來檢查你撰寫的程式是否正確: + +```bash +javascripting verify arrays.js +``` diff --git a/problems/arrays/solution_fr.md b/problems/arrays/solution_fr.md new file mode 100644 index 00000000..a573b1f9 --- /dev/null +++ b/problems/arrays/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# YAY, UN TABLEAU DE PIZZAS ! + +Vous avez réussi à créer un tableau ! + +Dans le défi suivant, nous allons explorer le filtrage de tableaux. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/arrays/solution_it.md b/problems/arrays/solution_it.md new file mode 100644 index 00000000..c33e5e48 --- /dev/null +++ b/problems/arrays/solution_it.md @@ -0,0 +1,11 @@ +--- + +# EVVIVA, UN ARRAY DI PIZZA! + +Hai creato con successo un array! + +Nella prossima sfida esploreremo come filtrare gli array. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/arrays/solution_nb-no.md b/problems/arrays/solution_nb-no.md new file mode 100644 index 00000000..0d054031 --- /dev/null +++ b/problems/arrays/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# YAY, ET PIZZA ARRAY! + +Du greide å lage et array! + +I den neste oppgaven skal vi utforske filtrering av arrayer. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/arrays/solution_nl.md b/problems/arrays/solution_nl.md new file mode 100644 index 00000000..45b1b86c --- /dev/null +++ b/problems/arrays/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# YEET, EEN PIZZA ARRAY! + +Je hebt met succes een array gemaakt! + +In de volgende uitdaging gaan we kijken hoe we arrays kunt filteren. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/arrays/solution_pt-br.md b/problems/arrays/solution_pt-br.md new file mode 100644 index 00000000..1ce86077 --- /dev/null +++ b/problems/arrays/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# AEEEE! UM ARRAY DE PIZZAS! + +Você criou um array com sucesso! + +No próximo desafio veremos como filtrar os arrays. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/arrays/solution_ru.md b/problems/arrays/solution_ru.md new file mode 100644 index 00000000..1894ff91 --- /dev/null +++ b/problems/arrays/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# УРА! ПИЦЦА-МАССИВ! + +Вам удалось создать массив! + +В следующей задаче мы разберёмся с фильтрацией массивов. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/arrays/solution_uk.md b/problems/arrays/solution_uk.md new file mode 100644 index 00000000..9110f6d5 --- /dev/null +++ b/problems/arrays/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# УРА, ПІЦА! + +Ви успішно створили масив! + +В наступному завданні ми дослідимо фільтрацію масивів. + +Запустіть `javascripting` в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/arrays/solution_zh-tw.md b/problems/arrays/solution_zh-tw.md new file mode 100644 index 00000000..a30a0c5c --- /dev/null +++ b/problems/arrays/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# YAY,一個披薩陣列! + +你成功地建立了一個陣列。 + +下一個挑戰裡我們將探索的是陣列過濾。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/for-loop/index.js b/problems/for-loop/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/for-loop/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/for-loop/problem.md b/problems/for-loop/problem.md index 6ad4991c..277048ce 100644 --- a/problems/for-loop/problem.md +++ b/problems/for-loop/problem.md @@ -1,22 +1,17 @@ ---- - -# FOR LOOPS - -For loops look like this: +For loops allow you to repeatedly run a block of code a certain number of times. This for loop logs to the console ten times: ```js -for (var i = 0; i < 10; i++) { +for (let i = 0; i < 10; i++) { // log the numbers 0 through 9 console.log(i) } ``` -The variable `i` is used to track how many times the loop has run. +The first part, `let i = 0`, is run once at the beginning of the loop. The variable `i` is used to track how many times the loop has run. -The statement `i < 10;` indicates the limit of the loop. -It will continue to loop if `i` is less than `10`. +The second part, `i < 10`, is checked at the beginning of every loop iteration before running the code inside the loop. If the statement is true, the code inside the loop is executed. If it is false, then the loop is complete. The statement `i < 10;` indicates that the loop will continue as long as `i` is less than `10`. -The statement `i++` increases the variable `i` by 1 each loop. +The final part, `i++`, is executed at the end of every loop. This increases the variable `i` by 1 after each loop. Once `i` reaches `10`, the loop will exit. ## The challenge: @@ -31,13 +26,15 @@ Create a for loop with a variable `i` starting at 0 and increasing by 1 each tim On each iteration of the loop, add the number `i` to the `total` variable. To do this, you can use this statement: ```js -total += i; +total += i ``` +When this statement is used in a for loop, it can also be known as _an accumulator_. Think of it like a cash register's running total while each item is scanned and added up. For this challenge, you have 10 items and they just happen to be increasing in price by 1 each item (with the first item free!). + After the for loop, use `console.log()` to print the `total` variable to the terminal. Check to see if your program is correct by running this command: -`javascripting verify for-loop.js` - ---- +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_es.md b/problems/for-loop/problem_es.md index b4ace994..e300abdf 100644 --- a/problems/for-loop/problem_es.md +++ b/problems/for-loop/problem_es.md @@ -1,18 +1,14 @@ ---- - -# FOR (BUCLES) - Un bucle for es como lo siguiente: ```js -for (var i = 0; i < 10; i++) { +for (let i = 0; i < 10; i++) { // imprime los números del 0 al 9 - console.log(i); + console.log(i) } ``` La variable `i` es utilizada como contador, en ella se almacenará la cantidad de veces que se ejecutó el bucle. -La expresión `i < 10;` indica el limite de veces que se ejecutara el código dentro del bucle. +La expresión `i < 10;` indica el limite de veces que se ejecutara el código dentro del bucle. Este continuara iterando si `i` es menor que `10`. La expresión `i++` incrementa la variable `i` en uno por cada iteración. @@ -30,13 +26,13 @@ Crea un for que itere 10 veces. En cada iteración, añade el valor de `i` a la Puedes utilizar lo siguiente: ```js -total += i; +total += i ``` Luego del for, utiliza `console.log()` para imprimir la variable `total` a la terminal. Comprueba si tu programa es correcto utilizando el siguiente comando: -`javascripting verify for.js` - ---- +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_fr.md b/problems/for-loop/problem_fr.md new file mode 100644 index 00000000..b4a00d50 --- /dev/null +++ b/problems/for-loop/problem_fr.md @@ -0,0 +1,38 @@ +Les boucles `for` vous permettent de répéter l'exécution d'un bloc de code un certain nombre de fois. Cette boucle `for` affiche dans la console dix fois : + +```js +for (let i = 0; i < 10; i++) { + // affiche les nombres de 0 a 9 + console.log(i) +} +``` + +La première partie, `let i = 0`, n'est exécutée qu'une fois au début de la boucle. La variable `i` est utilisée pour compter le nombre d'exécutions de la boucle. + +La seconde partie, `i < 10`, est vérifiée au début de chaque itération de la boucle avant que le code contenu ne s'exécute. Si la condition est valide, le code contenu dans la boucle est exécuté. Sinon, la boucle est terminée. La condition `i < 10;` indique que la boucle va continuer de s'exécuter tant que `i` est inférieur à `10`. + +La partie finale, `i++`, est exécutée à la fin de chaque boucle. Elle incrémente la variable `i` après chaque itération. Dès que `i` atteint 10, la boucle est terminée. + +## Le défi : + +Créez un fichier nommé `boucle-for.js`. + +Dans ce fichier, définissez une variable nommée `total` et assignez lui la valeur `0`. + +Créez une seconde variable nommée `limit` et assignez lui la valeur 10. + +Créez une boucle `for` avec une variable `i` commençant à 0 et s'incrémentant à chaque itération de la boucle. La boucle doit s'exécuter aussi longtemps que `i` est strictement inférieur à `limit`. + +À chaque itération de la boucle, ajoutez le nombre `i` à la variable `total`. Pour faire cela, vous pouvez utiliser l'instruction suivante : + +```js +total += i +``` + +Après la boucle, utilisez `console.log()` pour afficher la variable `total` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify boucle-for.js +``` diff --git a/problems/for-loop/problem_it.md b/problems/for-loop/problem_it.md new file mode 100644 index 00000000..98ab2315 --- /dev/null +++ b/problems/for-loop/problem_it.md @@ -0,0 +1,39 @@ +I cicli for si presentano come il seguente: + +```js +for (let i = 0; i < 10; i++) { + // scrive i numeri da 0 a 9 + console.log(i) +} +``` + +La variabile `i` viene usata per tenere il conto del numero di volte in cui il ciclo è stato eseguito. + +L'espressione `i < 10;` indica il limite del ciclo. +Il ciclo continuerà ad eseguire le istruzioni se `i` è minore di `10`. + +L'istruzione `i++` incrementa la variabile `i` di 1 ad ogni iterazione. + +## La sfida: + +Crea un file chiamato `for-loop.js`. + +In questo file definisci una variabile chiamata `total` e assegnale il numero `0`. + +Definisci una seconda variabile chiamata `limit` e assegnale il numero `10`. + +Crea un ciclo for con una variabile `i` che inizia da 0 e viene incrementata di 1 ad ogni iterazione del ciclo. Il ciclo deve essere eseguito finché `i` è minore di `limit`. + +Ad ogni iterazione del ciclo, aggiungi il valore di `i` alla variabile `total`. Per fare ciò, puoi usare quest'istruzione: + +```js +total += i +``` + +Al termine del ciclo for, usa `console.log()` per stampare la variabile `total` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_ja.md b/problems/for-loop/problem_ja.md index b618bd32..26cdeeb4 100644 --- a/problems/for-loop/problem_ja.md +++ b/problems/for-loop/problem_ja.md @@ -1,22 +1,24 @@ ---- - -# for ループ - -for ループの例です... +for ループを使うと、コードの塊を何回も繰り返し実行できます。 +次のfor ループはコンソールにログを10回書きます... ```js -for (var i = 0; i < 10; i++) { +for (let i = 0; i < 10; i++) { // log the numbers 0 through 9 console.log(i) } ``` -変数 `i` を使ってループを何回実行したか数えます。 +for ループでは、最初の部分 `let i = 0` をループの最初に一回だけ実行します。 +ループを実行した回数を数えるために、変数 `i` を使います。 -式 `i < 10` でループの終わりを示します。 -この条件では、 `i` が `10` 未満の間、ループします。 +第二の部分 `i < 10;` は、ループの繰り返し毎にチェックする条件式です。 +チェックした式が真の時、ループ内のコードを実行します。 +チェックした式が偽の時、ループを終了します。 +式 `i < 10;` の場合、 `i` が `10` 未満の間、ループを繰り返します。 -式 `i++` で、ループを一回まわるたびに、変数 `i` の値を増やします。 +最後の部分 `i++` を、ループが終わるたびに実行します。 +この式は、ループを一回まわるたびに、変数 `i` の値を `1` 増やします。 +`i` が `10` に達すると、ループを終了します。 ## やってみよう @@ -32,13 +34,13 @@ forループを作りましょう。変数 `i` を0から始めループのた ループを繰り返すたびに、 数値 `i` を `total` に足しましょう。こんな風に... ```js -total += i; +total += i ``` ループが終わったら、 `console.log()` を使い、変数 `total` をターミナルに表示しましょう。 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify for-loop.js` - ---- +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_ko.md b/problems/for-loop/problem_ko.md index b25af174..72b5dc1f 100644 --- a/problems/for-loop/problem_ko.md +++ b/problems/for-loop/problem_ko.md @@ -1,11 +1,7 @@ ---- - -# FOR 반복문 - for 반복문은 이렇게 생겼습니다. ```js -for (var i = 0; i < 10; i++) { +for (let i = 0; i < 10; i++) { // log the numbers 0 through 9 console.log(i) } @@ -31,13 +27,13 @@ for (var i = 0; i < 10; i++) { 각 반복마다 숫자 `i`를 `total` 변수에 더합니다. 이렇게 하려면, 이 구문을 사용하시면 됩니다. ```js -total += i; +total += i ``` for 반복문 다음에, `console.log()`를 사용해 `total` 변수를 터미널에 출력합니다. 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify for-loop.js` - ---- +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_nb-no.md b/problems/for-loop/problem_nb-no.md new file mode 100644 index 00000000..8e594bb1 --- /dev/null +++ b/problems/for-loop/problem_nb-no.md @@ -0,0 +1,39 @@ +For løkker ser slik ut: + +```js +for (let i = 0; i < 10; i++) { + // skriv ut nummerne fra 0 til 9 + console.log(i) +} +``` + +Variablen `i` brukes til å vite hvor mange ganger en løkke har kjørt. + +Uttrykket `i < 10;` indikerer grensen til en løkke. +Den vil fortsette i løkke så lenge `i` er mindre enn `10`. + +Resultatet av `i++` øker verdien til variablen `i` med 1 etter hver runde. + +## Oppgaven: + +Lag en fil som heter `for-loop.js`. + +Definer en variabel med navnet `total` i den filen og sett verdien til nummeret `0`. + +Definer en andre variabel med navnet `limit` og sett dens verdi til nummer `10`. + +Lag en for løkke med en variabel `i` som starter på 0 og økes med 1 hver runde gjennom løkken. Løkken skal kjøre så lenge `i` er mindre enn `limit`. + +I hver runde av løkken, legg til nummeret i variablen `i` til verdien i `total` variablen. Det kan gjøres på følgende måte: + +```js +total += i +``` + +Etter for løkken, bruk `console.log()` til å skrive ut verdien av `total` variablen til skjermen. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_nl.md b/problems/for-loop/problem_nl.md new file mode 100755 index 00000000..162b0ead --- /dev/null +++ b/problems/for-loop/problem_nl.md @@ -0,0 +1,42 @@ +Met "For loops" kun je een blok code meerdere keren uitvoeren. Deze loop print tien keer iets naar de console. + +```js +for (let i = 0; i < 10; i++) { + // log the numbers 0 through 9 + console.log(i) +} +``` + +Het eerste deel, `let i = 0`, wordt één keer uitgevoerd aan het begin van de loop iteratie. De variabele `i` wordt gebruikt om bij te houden hoe veel keer de loop is uitgevoerd. + +Het tweede deel, `i < 10`, wordt voor het begin van elke loop iteratie gecontroleerd. Als het logische statement true is (waar) dan wordt de code in de loop uitgevoerd. Als het false (niet waar) is, dan is de loop klaar. Het logische statement `i < 10;` geeft aan dat de loop uitgevoerd zal worden zolang `i` kleiner is dan `10`. + +Het laatste deel, `i++`, wordt aan het einde van elke loop iteratie uitgevoerd. Dit verhoogt de variabele `i` met 1 na elke loop iteratie. Zodra `i` gelijk wordt aan `10`, zal de loop stoppen. + +## De uitdaging + +Maak een nieuw bestand met de naam`for-loop.js`. + +Definieer een nieuwe variabele met de naam `total` en maak deze gelijk aan het getal `0`. + +Definieer nu een tweede variabele met de naam `limit` en maak deze gelijk aan het getal `10`. + +Schrijf een for loop waarbij de variabele `i` start bij 0 en die na elke loop met 1 ophoogt. De loop moet uitgevoerd worden zo lang `i` kleiner is dan `limit`. + +Tel in elke loop iteratie het getal `i` op bij de `total` variabele. Dit kun je doen met dit statement: + +```js +total += i +``` + +Als dit statement wordt gebruikt in een for loop, wordt dit ook wel een _accumulator_ genoemd. Denk aan een kassa waar je elke keer een nieuw artikel scant en het bedrag optelt bij het totaal. + +Bij deze uitdaging heb je dus 10 artikelen waarvan de prijs elke keer met 1 wordt opgehoogd (en waarbij het eerste artikel gratis is!) + +Gebruik `console.log()` NA de for loop om de waarde van de `total` naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_pt-br.md b/problems/for-loop/problem_pt-br.md new file mode 100644 index 00000000..f1386ad6 --- /dev/null +++ b/problems/for-loop/problem_pt-br.md @@ -0,0 +1,39 @@ +Loops com *for* são dessa forma: + +```js +for (let i = 0; i < 10; i++) { + // log the numbers 0 through 9 + console.log(i) +} +``` + +A variável `i` é usada para rastrear a quantidade de vezes em que o loop foi executado. + +A expressão `i < 10;` indica o limite do loop. +O loop continuará se o valor da variável `i` for menor que `10`. + +A expressão `i++` incrementa o valor da variável `i` a cada iteração. + +## Desafio: + +Crie um arquivo chamado `for-loop.js`. + +No arquivo que você acabou de criar, defina uma variável chamada `total` e inicialize ela com o valor `0`. + +Defina uma segunda variável chamada `limit` e inicialize ela com o valor `10`. + +Crie um loop for com a variável `i` iniciando do 0 aumentando por um 1 á cada iteração. O loop deverá correr enquanto o valor de `i` for menor que o valor de `limit`. + +Á cada iteração do loop, adicione o número do `i` á variável `total`. Para fazer isto, você pode usar a seguinte expressão: + +```js +total += i +``` + +Após o loop, use o `console.log()` para imprimir a variável `total` ao terminal. + +Verifique se o seu programa está correto executando este comando: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_ru.md b/problems/for-loop/problem_ru.md new file mode 100644 index 00000000..61a7f231 --- /dev/null +++ b/problems/for-loop/problem_ru.md @@ -0,0 +1,39 @@ +Цикл for позволяет выполнить заданный блок кода определённое количество раз. +Этот цикл for выводит значение переменной в консоль десять раз: + +```js +for (let i = 0; i < 10; i++) { + // выводим в консоль числа от 0 до 9 + console.log(i) +} +``` + +Первая часть конструкции цикла for, `let i = 0`, выполняется один раз в начале работы цикла. При этом переменная `i` в данном примере используется для хранения количества итераций цикла. + +Условие `i < 10;` проверяется в начале каждой итерации перед выполнением блока кода, заданного внутри цикла. Если условие является верным, то блок кода внутри цикла будет выполнен. В противном случае выполнение цикла завершается. Выражение `i < 10;` задаёт предел выполнения цикла. Цикл будет выполняться до тех пор, пока `i` будет строго меньше `10`. + +Последняя часть конструкции цикла for, выражение `i++`, выполняется в конце каждой итерации цикла, увеличивая переменную `i` на 1. Как только `i` достигнет `10`, выполнение цикла прекратится. + +## Условие задачи: + +Создайте файл `for-loop.js`. + +В этом файле объявите переменную `total` и присвойте ей значение `0`. + +Объявите вторую переменную -- `limit` и присвойте ей значение `10`. + +Создайте цикл for с переменной `i`, начальное значение которой 0. За каждый проход цикла переменная `i` должна увеличиваться на 1. Цикл должен работать до тех пор, пока значение `i` остаётся меньше значения переменной `limit`. + +Прибавляйте `i` к переменной `total` в каждой итерации цикла. Чтобы сделать это, воспользуйтесь следующим выражением: + +```js +total += i +``` + +Воспользуйтесь методом `console.log()`, чтобы вывести значение `total` в терминал после завершения работы цикла. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_uk.md b/problems/for-loop/problem_uk.md new file mode 100644 index 00000000..a6855bcb --- /dev/null +++ b/problems/for-loop/problem_uk.md @@ -0,0 +1,39 @@ +Цикл for виглядає ось так: + +```js +for (let i = 0; i < 10; i++) { + // log the numbers 0 through 9 + console.log(i) +} +``` + +Змінну `i` використовують для того, щоб бачити скільки разів цикл спрацював. + +Вираз `i < 10;` позначає межу циклу. +Він продовжуватиме виконуватись, до тих пір, поки `i` буде менше за `10`. + +Вираз `i++` збільшує змінну `i` на 1 після кожного виконання циклу. + +## Завдання: + +Створити файл `for-loop.js`. + +У цьому файлі визначити змінну `total` та присвоїти їй значення `0`. + +Визначити іншу змінну з назвою `limit` та встановити їй значення `10`. + +Написати цикл for зі змінною `i`, що стартуватиме зі значення 0 та збільшуватиметься на 1 при кожній ітерації циклу. Цикл має виконуватись допоки значення `i` буде менший за `limit`. + +На кожній ітерації циклу додавайте `i` до змінної `total`. Щоб зробити це, скористайтесь виразом: + +```js +total += i +``` + +Після циклу for, скористайтесь `console.log()`, щоб вивести значення `total` в термінал. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_zh-cn.md b/problems/for-loop/problem_zh-cn.md index a9b11ea6..2c543dda 100644 --- a/problems/for-loop/problem_zh-cn.md +++ b/problems/for-loop/problem_zh-cn.md @@ -1,11 +1,7 @@ ---- - -# FOR 循环 - For 循环看起来是这样的: ```js -for (var i = 0; i < 10; i++) { +for (let i = 0; i < 10; i++) { // log the numbers 0 through 9 console.log(i) } @@ -31,13 +27,13 @@ for (var i = 0; i < 10; i++) { 每次循环中,将 `i` 加到 `total` 上。你可以这样做: ```js -total += i; +total += i ``` For 循环结束后,使用 `console.log()` 打印 `total` 变量到终端。 运行下面的命令来检查你的程序是否正确: -`javascripting verify for-loop.js` - ---- +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/problem_zh-tw.md b/problems/for-loop/problem_zh-tw.md new file mode 100644 index 00000000..01dbc218 --- /dev/null +++ b/problems/for-loop/problem_zh-tw.md @@ -0,0 +1,39 @@ +For 迴圈看起來是這樣的: + +```js +for (let i = 0; i < 10; i++) { + // log the numbers 0 through 9 + console.log(i) +} +``` + +變數 `i` 被用來記錄迴圈已經運行了多少次。 + +條件式 `i < 10;` 指明了迴圈的上限。 +如果 `i` 小於 `10`,迴圈將繼續進行。 + +語句 `i++` 代表每次迴圈後將變數 `i` 的值加一。 + +## 挑戰: + +建立一個名為 `for-loop.js` 的檔案。 + +在該檔案中定義一個名為 `total` 的變數,讓它等於 `0`。 + +再定義第二個名為 `limit` 的變數,讓它等於 `10`。 + +建立一個 for 迴圈。使用變數 `i`,初始值為 0,每次迴圈將其值加一。只要 `i` 小於 `limit`,迴圈就應該一直運行。 + +每次迴圈中,將 `i` 加到 `total` 上。你可以這樣做: + +```js +total += i +``` + +For 迴圈結束後,使用 `console.log()` 印出 `total` 變數的值到終端機上。 + +執行下面的命令來檢查你撰寫的程式是否正確: + +```bash +javascripting verify for-loop.js +``` diff --git a/problems/for-loop/solution_fr.md b/problems/for-loop/solution_fr.md new file mode 100644 index 00000000..1dc74c39 --- /dev/null +++ b/problems/for-loop/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# LE TOTAL EST 45 + +Ceci était une introduction basique aux boucles. Elles sont utiles dans un grand nombre de situations, particulièrement dans des combinaisons avec d'autres types de données comme les chaînes de caractères et les tableaux. + +Dans le prochain défi, nous allons travailler sur les **tableaux**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/for-loop/solution_it.md b/problems/for-loop/solution_it.md new file mode 100644 index 00000000..df8545c3 --- /dev/null +++ b/problems/for-loop/solution_it.md @@ -0,0 +1,11 @@ +--- + +# IL TOTALE È 45 + +Questa era una introduzione basilare ai cicli for, che sono utili in una varietà di situazioni, in particolare in combinazione con altri tipi di dati come stringhe e array. + +Nella prossima sfida cominceremo a lavorare con gli **array**. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/for-loop/solution_nb-no.md b/problems/for-loop/solution_nb-no.md new file mode 100644 index 00000000..3d9b2a23 --- /dev/null +++ b/problems/for-loop/solution_nb-no.md @@ -0,0 +1,12 @@ +--- + +# TOTALEN ER 45 + +Det var en introduksjon til for løkker, som er veldig behjelpelig i mange situasjoner. +Spesielt i kombinasjon med andre data typer som strenger og arrayer. + +I den neste oppgaven skal vi starte og jobbe med **arrayer**. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/for-loop/solution_nl.md b/problems/for-loop/solution_nl.md new file mode 100644 index 00000000..91e070c5 --- /dev/null +++ b/problems/for-loop/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# HET TOTAAL IS 45 + +Dit was een basis inleiding van for-loops, die in een aantal situaties handig zijn, vooral in combinatie met andere gegevenstypen zoals strings en arrays. + +In de volgende uitdaging beginnen we met het gebruiken van **arrays**, + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/for-loop/solution_pt-br.md b/problems/for-loop/solution_pt-br.md new file mode 100644 index 00000000..7546e5f9 --- /dev/null +++ b/problems/for-loop/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# O TOTAL É 45 + +Isto foi uma introdução bem básica aos loops, dos quais são úteis em várias situações, particularmente em combinação com outros tipos de dados como strings e arrays. + +No próximo desafio começaremos á trabalhar com **arrays**. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/for-loop/solution_ru.md b/problems/for-loop/solution_ru.md new file mode 100644 index 00000000..db0ef1a3 --- /dev/null +++ b/problems/for-loop/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ПЕРЕМЕННАЯ TOTAL РАВНА 45 + +Мы ознакомились с основами использования циклов for, которые находят широкое применение при работе с различными типами данных, в особенности с такими как строки и массивы. + +В следующей задаче мы начнём работать с **массивами**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/for-loop/solution_uk.md b/problems/for-loop/solution_uk.md new file mode 100644 index 00000000..a71b321f --- /dev/null +++ b/problems/for-loop/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# TOTAL = 45 + +Це простий вступ до циклу for, який стає в ряді випадків, особливо поєднанні з іншими типами даних, як от рядки чи масиви. + +В наступному завданні ми почнемо працювати з **масивами**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/for-loop/solution_zh-tw.md b/problems/for-loop/solution_zh-tw.md new file mode 100644 index 00000000..766a7ce4 --- /dev/null +++ b/problems/for-loop/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# TOTAL 的值是 45 + +這是 for 迴圈的一個基本示例。For 迴圈在很多情況下十分有用,特別是在與像字串和陣列這樣的資料形態結合使用時。 + +下一個挑戰我們將開始學習 **arrays**,也就是**陣列**。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/function-arguments/index.js b/problems/function-arguments/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/function-arguments/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/function-arguments/problem.md b/problems/function-arguments/problem.md index ee65b641..ec01012d 100644 --- a/problems/function-arguments/problem.md +++ b/problems/function-arguments/problem.md @@ -1,21 +1,17 @@ ---- - -# FUNCTION ARGUMENTS - A function can be declared to receive any number of arguments. Arguments can be from any type. An argument could be a string, a number, an array, an object and even another function. Here is an example: ```js function example (firstArg, secondArg) { - console.log(firstArg, secondArg); + console.log(firstArg, secondArg) } ``` We can **call** that function with two arguments like this: ```js -example('hello', 'world'); +example('hello', 'world') ``` The above example will print to the terminal `hello world`. @@ -28,12 +24,12 @@ In that file, define a function named `math` that takes three arguments. It's im Name each argument as you like. -The function `math` should multiply the second and third arguments, then add the first argument to the outcome of the multiplication and return the value obtained. +Within the `math` function, return the value obtained from multiplying the second and third arguments and adding that result to the first argument. After that, inside the parentheses of `console.log()`, call the `math()` function with the number `53` as first argument, the number `61` as second and the number `67` as third argument. Check to see if your program is correct by running this command: -`javascripting verify function-arguments.js` - ---- +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_es.md b/problems/function-arguments/problem_es.md index 943edc63..46f4af27 100644 --- a/problems/function-arguments/problem_es.md +++ b/problems/function-arguments/problem_es.md @@ -1,14 +1,10 @@ ---- - -# ARGUMENTOS DE FUNCIÓN - Una función puede ser declarada para recibir cualquier número de argumentos. Los argumentos pueden ser de cualquier tipo. Por ejemplo, un argumento a una función podría ser una string, un número, un array, un objeto e incluso otra función. Un ejemplo: ```js function example (firstArg, secondArg) { - console.log(firstArg, secondArg); + console.log(firstArg, secondArg) } ``` @@ -16,7 +12,7 @@ Podemos **llamar** a la función con dos argumentos de la siguiente forma: ```js -example('hello', 'world'); +example('hello', 'world') ``` El ejemplo anterior imprimirá `hello world` a la terminal. @@ -36,6 +32,6 @@ Luego de eso, dentro de los paréntesis de `console.log()`, llamá la función ` Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify function-arguments.js` - ---- +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_fr.md b/problems/function-arguments/problem_fr.md new file mode 100644 index 00000000..f580bbff --- /dev/null +++ b/problems/function-arguments/problem_fr.md @@ -0,0 +1,35 @@ +On peut déclarer qu'une fonction reçoit n'importe quel nombre d'arguments. Les arguments peuvent être de n'importe quel type : un argument peut être une chaîne de caractères, un nombre, un tableau, un objet et même une autre fonction. + +Voici un exemple : + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +Nous pouvons **appeler** cette fonction avec deux arguments comme cela : + +```js +example('hello', 'world') +``` + +L'exemple ci-dessus va afficher dans le terminal `hello world`. + +## Le défi : + +Créez un fichier nommé `arguments-de-fonction.js`. + +Dans ce fichier, définissez une fonction nommée `math` qui prend trois arguments. Il est important que vous compreniez que les noms d'arguments ne sont seulement utilisés que pour y faire référence. + +Nommez chaque argument comme vous le souhaitez. + +Dans la fonction `math`, renvoyez la valeur obtenue de la multiplication du second argument avec le troisième et en ajoutant le premier argument au résultat. + +Après cela, dans les parenthèses de `console.log()`, appelez la fonction `math()` avec le nombre `53` comme premier argument, le nombre `61` comme second et le nombre `67` en troisième argument. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify arguments-de-fonction.js +``` diff --git a/problems/function-arguments/problem_it.md b/problems/function-arguments/problem_it.md new file mode 100644 index 00000000..1e394881 --- /dev/null +++ b/problems/function-arguments/problem_it.md @@ -0,0 +1,35 @@ +È possibile dichiarare una funzione perché riceva un numero qualsiasi di argomenti. Gli argomenti possono essere di qualunque tipo. Un argomento può essere una stringa, un numero, un array, un oggetto oppure un'altra funzione. + +Ecco un esempio: + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +Possiamo **invocare** questa funzione con due argomenti come segue: + +```js +example('ciao', 'mondo') +``` + +L'esempio precedente scriverà `ciao mondo` sul terminale. + +## La sfida: + +Crea un file dal nome `function-arguments.js`. + +In questo file, definisci una funzione dal nome `math` che riceve tre argomenti. È importante capire che i nomi degli argomenti sono usati soltanto per fare ad essi riferimento. + +Dài a ciascun argomento il nome che desideri. + +Nella funzione `math`, restituisci il valore ottenuto dalla moltiplicazione del secondo e terzo argomento, e sommando il risultato al primo argomento. + +Dopo di ciò, dentro le parentesi di `console.log()`, invoca la funzione `math()` con il numero `53` come primo argomento, il numero `61` come secondo argomento, e il numero `67` come terzo argomento. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_ja.md b/problems/function-arguments/problem_ja.md index 03e21b65..1facf3c2 100644 --- a/problems/function-arguments/problem_ja.md +++ b/problems/function-arguments/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 関数の引数 - 関数の引数はいくつでも宣言できます。引数はどんな型でも大丈夫です。文字列、数値、配列、オブジェクト、関数さえも引数になり得ます。 たとえば... @@ -9,14 +5,14 @@ ```js function example (firstArg, secondArg) { - console.log(firstArg, secondArg); + console.log(firstArg, secondArg) } ``` 引数が2つの関数を**呼び出す**には、次のようにします。 ```js -example('hello', 'world'); +example('hello', 'world') ``` 上の例を実行すると、ターミナルに `hello world` と出力されるでしょう。 @@ -35,6 +31,6 @@ example('hello', 'world'); 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify function-arguments.js` - ---- +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_ko.md b/problems/function-arguments/problem_ko.md index 9303f81a..7f387614 100644 --- a/problems/function-arguments/problem_ko.md +++ b/problems/function-arguments/problem_ko.md @@ -1,21 +1,17 @@ ---- - -# 함수 인자 - 함수는 몇 개의 인자도 받도록 선언할 수 있습니다. 인자는 어떤 타입도 사용 가능합니다. 인자는 문자열, 숫자, 배열, 객체이거나 심지어 다른 함수일 수도 있습니다. 여기 예제가 있습니다. ```js function example (firstArg, secondArg) { - console.log(firstArg, secondArg); + console.log(firstArg, secondArg) } ``` 우리는 두 개의 인자를 가지는 함수를 이렇게 **호출**할 수 있습니다. ```js -example('hello', 'world'); +example('hello', 'world') ``` 위 예제는 터미널에 `hello world`를 출력할 것입니다. @@ -27,7 +23,7 @@ example('hello', 'world'); 이 파일에서는 3개의 인자를 받는 `math`라는 이름의 함수를 선언합니다. 인자 이름은 참조로만 사용한다는 것을 이해하는 것은 중요합니다. -각 인자는 좋아하는 이름을 지으세요. +인자들에는 편한 이름을 지으세요. `math` 함수는 두 번째와 세 번째 인자를 곱하고, 곱한 값에 첫 번째 인자를 더해 얻은 결과를 출력합니다. @@ -35,6 +31,6 @@ example('hello', 'world'); 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify function-arguments.js` - ---- +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_nb-no.md b/problems/function-arguments/problem_nb-no.md new file mode 100644 index 00000000..f38b7244 --- /dev/null +++ b/problems/function-arguments/problem_nb-no.md @@ -0,0 +1,35 @@ +En funksjon kan deklareres til å ta imot så mange argumenter som nødvendig. Argumentene kan være av alle slags typer; en string, et nummer, et array, et objekt og tilogmed en annen funksjon. + +Her er et eksempel: + +```js +function eksempel (argNr1, argNr2) { + console.log(argNr1, argNr2) +} +``` + +Vi kan **kalle** den funksjonen med to argumenter på denne måten: + +```js +eksempel('hello', 'world') +``` + +Eksemplet over vil skrive ut `hello world` til skjermen. + +## Oppgaven: + +Lag en fil som heter `function-arguments.js`. + +Definer en funksjon med navnet `math` i den filen, som tar imot tre argumenter. Det er viktig at du forstår at argumentenes navn kun brukes til å referere de. + +Gi argumentene hvilke navn som helst. + +Funksjonen `math` skal multiplisere det andre argumentet med det tredje, deretter legge til det første argumentet til resultatet av multiplikasjonen. + +Tilslutt, inni parantesene til `console.log`, kaller du `match` funksjonen med nummeret `53` som første argument, nummeret `61` som andre argument og tilslutt nummeret `67` som tredje argument. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_nl.md b/problems/function-arguments/problem_nl.md new file mode 100755 index 00000000..1e0fecbf --- /dev/null +++ b/problems/function-arguments/problem_nl.md @@ -0,0 +1,35 @@ +Je kunt een function zo declareren dat een willekeurig aantal argumenten kan ontvangen. Argumenten mogen van elk type zijn. Een argument kan dus een string, een number, een array, een object of zelfs een andere function zijn. + +Hier is een voorbeeld: + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +Je kunt deze function **aanroepen** met twee argumenten zoals hieronder: + +```js +example('hello', 'world') +``` + +Dit voorbeeld print `hello world` naar de console. + +## De uitdaging: + +Maak een nieuw bestand met de naam `function-arguments.js`. + +Definieer in dit bestand een function met de naam `math` die drie argumenten ontvangt. Het is belangrijk dat je begrijpt dat de namen van argumenten alleen worden gebruikt als verwijzing. + +Geef elk argument de naam die je zelf wilt. + +Binnen de `math` function vermenigvuldig je het tweede en derde argument met elkaar. Het resultaat van deze berekening tel je op bij het eerste argument. Geef het resultaat terug met `return`. + +Na de function roep je binnen de haakjes van `console.log()`, de `math()` function aan met het getal `53` als eerste argument, het getal `61` als tweede argument en het getal `67` als derde argument. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_pt-br.md b/problems/function-arguments/problem_pt-br.md new file mode 100644 index 00000000..86796536 --- /dev/null +++ b/problems/function-arguments/problem_pt-br.md @@ -0,0 +1,35 @@ +Podemos declarar uma função que recebe qualquer quantidade de argumentos. Os argumentos podem ser de qualquer tipo. Um argumento poderia ser uma string, um número, um array, um objeto e até mesmo outra função. + +Aqui está um exemplo: + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +Podemos **chamar** essa função passando dois argumentos dessa forma: + +```js +example('hello', 'world') +``` + +O exemplo acima irá imprimir no terminal `hello world`. + +## Desafio: + +Crie um arquivo chamado `function-arguments.js`. + +Nesse arquivo, defina uma função chamada `math` que recebe 3 argumentos. É importante compreender que o nome dos argumentos são usados somente para referenciá-los. + +Dê um nome para cada argumento da maneira que você quiser. + +A função `math` deverá multiplicar o segundo e o terceiro argumento, e então somar o primeiro argumento ao resultado da multiplicação e então retornar o valor obtido. + +Depois disso, dentro dos parênteses do `console.log()`, chame a função `math()` com o número `53` como primeiro argumento, `61` como segundo e `67` como terceiro argumento. + +Verifique se o seu programa está correto executando esse comando: + +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_ru.md b/problems/function-arguments/problem_ru.md new file mode 100644 index 00000000..ac768528 --- /dev/null +++ b/problems/function-arguments/problem_ru.md @@ -0,0 +1,35 @@ +Функция может быть объявлена с любым количеством аргументов. В качестве аргумента может выступать любой тип данных. Это может быть строка, число, массив, объект или даже другая функция. + +Например: + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +Вот так можно **вызвать** эту функцию с двумя аргументами: + +```js +example('hello', 'world') +``` + +Указанный пример выведет на экран терминала `hello world`. + +## Условие задачи: + +Создайте файл `function-arguments.js`. + +В этом файле объявите функцию `math` которая принимает три аргумента. Важно понять, что названия аргументов используются только для того чтобы ссылаться на них. + +Назовите аргументы как вам нравится. + +В функции `math` перемножьте второй и третий аргументы, затем прибавьте к произведению первый аргумент и верните вычисленное значение. + +После этого, внутри скобок выражения `console.log()` вызовите функцию `math()` передав в качестве первого аргумента число `53`, в качестве второго аргумента число `61` и в качестве третьего аргумента число `67`. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify function-arguments.js +``` \ No newline at end of file diff --git a/problems/function-arguments/problem_uk.md b/problems/function-arguments/problem_uk.md new file mode 100644 index 00000000..0765e7b5 --- /dev/null +++ b/problems/function-arguments/problem_uk.md @@ -0,0 +1,36 @@ +Функція може отримувати будь-яке число аргументів. Аргументами можуть бути будь-якого типу. Аргументом може бути рядок, число, масив, об’єкт або навіть інша функція. + +Приклад: + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +Ми можемо **викликати** цю функцію з двома аргументами таким чином: + +```js +example('hello', 'world') +``` + +Приклад вище виведе в термінал `hello world`. + +## Завдання: + +Створити файл `function-arguments.js`. + +В цьому файлі оголосити функцію під назвою `math`, яка прийматиме три аргументи. Важливо розуміти, що назви аргументів використовуються лише для звертання до їх значення. + +Назвіть аргументи за власним бажанням. + +В середині функції `math`, поверніть значення, отримане шляхом множення другого та третього аргументів і додаванням результату до першого аргументу. + +Після цього, всередині круглих дужок в `console.log()`, викличіть функцію `math()` з числом `53` в якості першого аргументу, числом `61` в якості другого аргументу та числом `67` в якості третього аргументу. + + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_zh-cn.md b/problems/function-arguments/problem_zh-cn.md index a8ae4c1c..777677d8 100644 --- a/problems/function-arguments/problem_zh-cn.md +++ b/problems/function-arguments/problem_zh-cn.md @@ -1,21 +1,17 @@ ---- - -# 函数的参数 - 一个函数可以被声明为接受任意数量的参数。参数可以是任意的类型,例如字符串,数字,数组,对象,甚至另一个函数。 例子: ```js function example (firstArg, secondArg) { - console.log(firstArg, secondArg); + console.log(firstArg, secondArg) } ``` 我们可以**调用**这个函数,并给它两个参数: ```js -example('hello', 'world'); +example('hello', 'world') ``` 上面的代码将打印 `hello world` 到终端。 @@ -34,6 +30,6 @@ example('hello', 'world'); 运行下面的命令检查你的程序是否正确: -`javascripting verify function-arguments.js` - ---- +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/problem_zh-tw.md b/problems/function-arguments/problem_zh-tw.md new file mode 100644 index 00000000..0cd8d020 --- /dev/null +++ b/problems/function-arguments/problem_zh-tw.md @@ -0,0 +1,35 @@ +一個函式可以被宣告為接受任意數量的參數。參數可以是任意的型別,例如字串、數字、陣列、物件,甚至是另一個函式。 + +範例: + +```js +function example (firstArg, secondArg) { + console.log(firstArg, secondArg) +} +``` + +我們可以**呼叫**這個函式,並給它兩個參數: + +```js +example('hello', 'world') +``` + +上面的程式碼將印出 `hello world` 到終端機上。 + +## 挑戰: + +建立一個名為 `function-arguments.js` 的檔案。 + +在該檔案中,定義一個名為 `math` 的函式,它接受三個參數。你需要知道的是,參數的名字僅僅是用來引用它們的而已。 + +所以你可以給它們起任何你喜歡的名字。 + +`math` 所做的工作是,將第二個和第三個參數相乘,然後加上第一個參數,再將最後的結果回傳。 + +之後,使用 `console.log()` 呼叫並印出函式的執行結果。呼叫時,函式的第一個參數是 `53`,第二個參數是 `61`,第三個參數是 `67`。 + +執行下面的命令來檢查你撰寫的程式是否正確: + +```bash +javascripting verify function-arguments.js +``` diff --git a/problems/function-arguments/solution_fr.md b/problems/function-arguments/solution_fr.md new file mode 100644 index 00000000..9de07214 --- /dev/null +++ b/problems/function-arguments/solution_fr.md @@ -0,0 +1,10 @@ +--- + +# VOUS CONTRÔLEZ VOS ARGUMENTS ! + + +Vous avez bien réussi l'exercice. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/function-arguments/solution_it.md b/problems/function-arguments/solution_it.md new file mode 100644 index 00000000..4412f736 --- /dev/null +++ b/problems/function-arguments/solution_it.md @@ -0,0 +1,9 @@ +--- + +# HAI IL CONTROLLO DEI TUOI ARGOMENTI! + +Ottimo lavoro nel completare l'esercizio. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/function-arguments/solution_nb-no.md b/problems/function-arguments/solution_nb-no.md new file mode 100644 index 00000000..b22d1822 --- /dev/null +++ b/problems/function-arguments/solution_nb-no.md @@ -0,0 +1,9 @@ +--- + +# DU HAR KONTROLL PÅ ARGUMENTENE DINE! + +Bra jobba med å fullføre oppgaven. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/function-arguments/solution_nl.md b/problems/function-arguments/solution_nl.md new file mode 100644 index 00000000..070236ab --- /dev/null +++ b/problems/function-arguments/solution_nl.md @@ -0,0 +1,9 @@ +--- + +# JE HEBT CONTROLE OVER JE ARGUMENTEN! + +Complimenten voor het afronden van deze uitdaging. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/function-arguments/solution_pt-br.md b/problems/function-arguments/solution_pt-br.md new file mode 100644 index 00000000..4bab4bd7 --- /dev/null +++ b/problems/function-arguments/solution_pt-br.md @@ -0,0 +1,9 @@ +--- + +# VOCÊ DOMINOU OS ARGUMENTOS! + +Muito bom! Você conseguiu completar o exercício. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/function-arguments/solution_ru.md b/problems/function-arguments/solution_ru.md new file mode 100644 index 00000000..e8d1b089 --- /dev/null +++ b/problems/function-arguments/solution_ru.md @@ -0,0 +1,9 @@ +--- + +# ВЫ УПРАВЛЯЕТЕ АРГУМЕНТАМИ! + +Задание успешно выполнено. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- \ No newline at end of file diff --git a/problems/function-arguments/solution_uk.md b/problems/function-arguments/solution_uk.md new file mode 100644 index 00000000..90bc7bc0 --- /dev/null +++ b/problems/function-arguments/solution_uk.md @@ -0,0 +1,9 @@ +--- + +# ВИ КОНТРОЛЮЄТЕ ВАШІ АРГУМЕНТИ! + +Відмінна робота. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/function-arguments/solution_zh-tw.md b/problems/function-arguments/solution_zh-tw.md new file mode 100644 index 00000000..34c6a1e0 --- /dev/null +++ b/problems/function-arguments/solution_zh-tw.md @@ -0,0 +1,9 @@ +--- + +# 你現在完全掌控了參數! + +幹得漂亮。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/function-return-values/index.js b/problems/function-return-values/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/function-return-values/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/function-return-values/problem_fr.md b/problems/function-return-values/problem_fr.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_fr.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_it.md b/problems/function-return-values/problem_it.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_it.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_nb-no.md b/problems/function-return-values/problem_nb-no.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_nb-no.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_nl.md b/problems/function-return-values/problem_nl.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_nl.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_pt-br.md b/problems/function-return-values/problem_pt-br.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_pt-br.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_ru.md b/problems/function-return-values/problem_ru.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_ru.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_uk.md b/problems/function-return-values/problem_uk.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_uk.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/problem_zh-tw.md b/problems/function-return-values/problem_zh-tw.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/problem_zh-tw.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_fr.md b/problems/function-return-values/solution_fr.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_fr.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_it.md b/problems/function-return-values/solution_it.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_it.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_nb-no.md b/problems/function-return-values/solution_nb-no.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_nb-no.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_nl.md b/problems/function-return-values/solution_nl.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_nl.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_pt-br.md b/problems/function-return-values/solution_pt-br.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_pt-br.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_ru.md b/problems/function-return-values/solution_ru.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_ru.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_uk.md b/problems/function-return-values/solution_uk.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_uk.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/function-return-values/solution_zh-tw.md b/problems/function-return-values/solution_zh-tw.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/function-return-values/solution_zh-tw.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/functions/index.js b/problems/functions/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/functions/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/functions/problem.md b/problems/functions/problem.md index feca7c1f..eb4de8cf 100644 --- a/problems/functions/problem.md +++ b/problems/functions/problem.md @@ -1,14 +1,10 @@ ---- - -# FUNCTIONS - A function is a block of code that takes input, processes that input, and then produces output. Here is an example: ```js function example (x) { - return x * 2; + return x * 2 } ``` @@ -24,19 +20,19 @@ The above example assumes that the `example` function will take a number as an a Create a file named `functions.js`. -In that file, define a function named `eat` that takes an argument named `food` +In that file, define a function named `eat` that takes an argument named `food` that is expected to be a string. Inside the function return the `food` argument like this: ```js -return food + ' tasted really good.'; +return food + ' tasted really good.' ``` Inside of the parentheses of `console.log()`, call the `eat()` function with the string `bananas` as the argument. Check to see if your program is correct by running this command: -`javascripting verify functions.js` - ---- +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_es.md b/problems/functions/problem_es.md index efd66577..b589d3e0 100644 --- a/problems/functions/problem_es.md +++ b/problems/functions/problem_es.md @@ -1,7 +1,3 @@ ---- - -# FUNCIONES - Una función es un bloque de código que puede recibir un input y devolver un output. Vamos a utilizar la palabra reservada `return` para especificar lo que devuelve una función. @@ -10,7 +6,7 @@ Vamos a utilizar la palabra reservada `return` para especificar lo que devuelve Por ejemplo: ```js function example (x) { - return x * 2; + return x * 2 } ``` @@ -31,13 +27,13 @@ En ese archivo, define una función llamada `eat` que reciba un argumento llamad Dentro de la función, retorna el argumento `food` de la siguiente manera: ```js -return food + ' tasted really good.'; +return food + ' tasted really good.' ``` Dentro de los paréntesis de `console.log()`, llama a la función `eat()` con la string `bananas` cómo argumento. Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify functions.js` - ---- +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_fr.md b/problems/functions/problem_fr.md new file mode 100644 index 00000000..d604c38d --- /dev/null +++ b/problems/functions/problem_fr.md @@ -0,0 +1,37 @@ +Une fonction est un bloc de code qui prend des entrées, qui traite ces entrées, et produit une sortie. + +Voici un exemple : + +```js +function example (x) { + return x * 2 +} +``` + +Nous pouvons **appeler** cette fonction comme cela pour récupérer le nombre 10 : + +```js +example(5) +``` + +L'exemple ci-dessus part du principe que la fonction `example` prend en argument — en entrée — un nombre et va renvoyer ce nombre multiplié par 2. + +## Le défi : + +Créez un fichier nommé `fonctions.js`. + +Dans ce fichier, définissez une fonction nommée `eat` qui prend un argument nommé `food` qui est considéré comme étant une chaîne de caractères. + +Dans cette fonction, retournez l'argument `food` comme cela : + +```js +return food + ' tasted really good.' +``` + +Dans les parenthèses de `console.log()`, appelez la fonction `eat()` avec la chaîne de caractères `bananas` comme argument. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify fonctions.js +``` diff --git a/problems/functions/problem_it.md b/problems/functions/problem_it.md new file mode 100644 index 00000000..2a2582cd --- /dev/null +++ b/problems/functions/problem_it.md @@ -0,0 +1,38 @@ +Una funzione è un blocco di codice che riceve dati di input, li processa, e infine produce un output. + +Ecco un esempio: + +```js +function example (x) { + return x * 2 +} +``` + +Possiamo **invocare** questa funzione come segue per ottenere il numero 10: + +```js +example(5) +``` + +L'esempio precedente assume che la funzione `example` riceverà un numero come argomento –– ovvero input –– e restituirà quel numero moltiplicato per 2. + +## La sfida: + +Crea un file dal nome `functions.js`. + +In questo file, definisci una funzione dal nome `eat` che accetta un argomento di nome `food` +che ci si aspetta sia una stringa. + +All'interno della funzione restituisci l'argomento `food` come segue: + +```js +return food + ' tasted really good.' +``` + +Dentro le parentesi di `console.log()`, invoca la funzione `eat()` con la stringa `bananas` come argomento. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_ja.md b/problems/functions/problem_ja.md index 697233b4..e1ec7577 100644 --- a/problems/functions/problem_ja.md +++ b/problems/functions/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 関数 - 関数はコードのまとまりです。入力を受け取ります。受け取った入力を処理し、結果を返します。 たとえば... @@ -9,7 +5,7 @@ ```js function example (x) { - return x * 2; + return x * 2 } ``` @@ -24,7 +20,7 @@ example(5) ## やってみよう -`function.js` ファイルを作りましょう。 +`functions.js` ファイルを作りましょう。 ファイルの中で、関数 `eat` を定義します。`eat` は、ひとつの引数 `food` を受け取ります。 @@ -33,13 +29,13 @@ example(5) 関数内で、 `food` 引数を次のように処理して返してください... ```js -return food + ' tasted really good.'; +return food + ' tasted really good.' ``` `console.log()` の括弧の中で、 `eat()` 関数を呼んで、引数として `bananas` という文字列を与えてください。 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify functions.js` - ---- +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_ko.md b/problems/functions/problem_ko.md index 560853ed..9803382c 100644 --- a/problems/functions/problem_ko.md +++ b/problems/functions/problem_ko.md @@ -1,14 +1,10 @@ ---- - -# 함수 - 함수는 입력을 받는 코드의 블록입니다. 그 입력을 처리해서 출력을 만듭니다. 여기에 예제가 있습니다. ```js function example (x) { - return x * 2; + return x * 2 } ``` @@ -29,13 +25,13 @@ example(5) 함수 안에서 `food` 인자를 이렇게 반환합니다. ```js -return food + ' tasted really good.'; +return food + ' tasted really good.' ``` `console.log()`의 괄호 안에서 문자열 `bananas`를 인자로 하는 `eat()` 함수를 호출합니다. 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify functions.js` - ---- +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_nb-no.md b/problems/functions/problem_nb-no.md new file mode 100644 index 00000000..de157445 --- /dev/null +++ b/problems/functions/problem_nb-no.md @@ -0,0 +1,38 @@ +En funksjon er en samling kode som tar imot data, prosesserer den dataen og lager et resultat. + + +Her er et eksempel: + +```js +function eksempel (x) { + return x * 2 +} +``` + +Vi kan **kalle** denne funksjonen slik som dette for å få nummeret 10: + +```js +eksempel(5) +``` + +Eksemplet over antar at `eksempel` funksjonen tar et nummer som et argument og returner et tall som multipliseres med 2. + +## Oppgaven: + +Lag en fil som heter `functions.js`. + +Definer en funksjon med navnet `eat` i den filen som tar i mot argumentet med navn `food` som forventes å være en string. + +På innsiden av den funksjonen skal du returnere `food` argumentet slik som dette: + +```js +return food + ' tasted really good.' +``` + +Inni parantesene til `console.log()`, kall `eat()` funksjonen med stringen `bananas` som argument. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_nl.md b/problems/functions/problem_nl.md new file mode 100755 index 00000000..c7505aa3 --- /dev/null +++ b/problems/functions/problem_nl.md @@ -0,0 +1,37 @@ +Een function is een blok met code die input ontvangt, deze input verwerkt, en een output teruggeeft. + +Een voorbeeld: + +```js +function example (x) { + return x * 2 +} +``` + +Je kunt deze function **aanroepen** zoals hieronder om het getal 10 te krijgen: + +```js +example(5) +``` + +Dit voorbeeld gaat er van uit dat de `example` function een number als argument krijgt –– als input –– en als output (return) het number vermenigvuldigt met 2 teruggeeft. + +## De uitdaging + +Maak een nieuw bestand met de naam `functions.js`. + +Definieer in dit bestand een function met de naam `eat` die een argument genaamd `food` krijgt (waarvan we verwachten dat het een string is). + +Geef het `food` argument in de function terug zoals hier: + +```js +return food + ' tasted really good.' +``` + +Roep nu de binnen de haakjes van `console.log()`, de `eat()` function aan met de string `bananas` als argument. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_pt-br.md b/problems/functions/problem_pt-br.md new file mode 100644 index 00000000..aff3843b --- /dev/null +++ b/problems/functions/problem_pt-br.md @@ -0,0 +1,38 @@ +Uma função basicamente recebe uma entrada, processa a entrada, e então produz uma saída. + +Aqui está um exemplo: + +```js +function example (x) { + return x * 2 +} +``` + +Podemos **chamar** a função `example` dessa forma para conseguir o número 10: + +```js +example(5) +``` + +O exemplo acima assume que a função `example` irá receber um número como um argumento/parâmetro –– ou seja, como entrada –– e irá retornar este número multiplicado por 2. + +## Desafio: + +Crie um arquivo chamado `functions.js`. + +Neste arquivo, defina uma função chamada `eat` que recebe um argumento chamado `food` +que deverá ser uma string. + +De dentro da função retorne o argumento `food` dessa maneira: + +```js +return food + ' tasted really good.' +``` + +Dentro do parênteses do `console.log()`, chame a função `eat()` com a string `bananas` como argumento. + +Verifique se o seu programa está correto executando este comando: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_ru.md b/problems/functions/problem_ru.md new file mode 100644 index 00000000..f6a1c30b --- /dev/null +++ b/problems/functions/problem_ru.md @@ -0,0 +1,37 @@ +Функция это блок кода, который берет входные данные, обрабатывает их и затем возвращает результат. + +Например: + +```js +function example (x) { + return x * 2 +} +``` + +Вот так можно **вызвать** эту функцию, чтобы получить число 10: + +```js +example(5) +``` + +Приведенный выше пример показывает, что функция `example` возьмет в качестве аргумента число - входные данные - и вернет это число умноженным на 2. + +## Условие задачи: + +Создайте файл `functions.js`. + +В этом файле определите функцию `eat`, принимающую один строковый аргумент под названием `food`. + +Внутри функции используйте аргумент `food` и верните следующий результат: + +```js +return food + ' tasted really good.' +``` + +Внутри скобок выражения `console.log()` вызовите функцию `eat()`, указав в качестве аргумента строку `bananas`. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_uk.md b/problems/functions/problem_uk.md new file mode 100644 index 00000000..c1a93038 --- /dev/null +++ b/problems/functions/problem_uk.md @@ -0,0 +1,37 @@ +Функція — це блок коду, що приймає деякі аргументи, оперує цими аргументами та повертає результат. + +Приклад: + +```js +function example (x) { + return x * 2 +} +``` + +Ми можемо **викликати** цю функцію таким чином, щоб отримати число 10: + +```js +example(5) +``` + +Приклад вище ілюструє, що функція `example` буде приймати число в якості аргументу — як вхід — та буде повертати це число помножене на 2. + +## Завдання: + +Створити файл `functions.js`. + +У цьому файлі оголосити функцію `eat`, що приймає аргумент під назвою `food`, який має бути рядком. + +Всередині функції повернуть аргумент `food` ось так: + +```js +return food + ' tasted really good.' +``` + +Всередині круглих дужок в `console.log()`, викличіть функцію `eat()` з рядком `bananas` в якості аргументу. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_zh-cn.md b/problems/functions/problem_zh-cn.md index 521f5d92..dfb234cb 100644 --- a/problems/functions/problem_zh-cn.md +++ b/problems/functions/problem_zh-cn.md @@ -1,14 +1,10 @@ ---- - -# 函数 - 函数就是一大段代码,这段代码将输入处理,然后产生输出。 例子: ```js function example (x) { - return x * 2; + return x * 2 } ``` @@ -29,13 +25,13 @@ example(5) 在函数中将 `food` 参数处理后像下面这样返回: ```js -return food + ' tasted really good.'; +return food + ' tasted really good.' ``` 在 `console.log()` 的括号中,调用 `eat()` 函数,并把字符串 `bananas` 当做参数传递给它。 运行下面的命令检查你的程序是否正确: -`javascripting verify functions.js` - ---- +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/problem_zh-tw.md b/problems/functions/problem_zh-tw.md new file mode 100644 index 00000000..1d90ac87 --- /dev/null +++ b/problems/functions/problem_zh-tw.md @@ -0,0 +1,37 @@ +函式就是一段程式碼,這段程式碼將輸入處理,然後產生輸出。 + +範例: + +```js +function example (x) { + return x * 2 +} +``` + +我們可以像下面這樣**呼叫**這個函式,得到數字 10: + +```js +example(5) +``` + +上面的這段程式碼裡,`example` 函式將一個數字作為參數——也就是輸入——然後返回那個數字乘以 2 的結果。 + +## 挑戰: + +建立一個名為 `functions.js` 的檔案。 + +在該檔案中,定義一個名為 `eat` 的函式,其參數名為 `food`,型別為 `string`。 + +在函式中將 `food` 參數處理後像下面這樣返回: + +```js +return food + ' tasted really good.' +``` + +在 `console.log()` 的括號中,呼叫 `eat()` 函式,並把字串 `bananas` 當做參數傳遞給它。 + +執行下面的命令檢查你撰寫的程式是否正確: + +```bash +javascripting verify functions.js +``` diff --git a/problems/functions/solution_fr.md b/problems/functions/solution_fr.md new file mode 100644 index 00000000..a43657b6 --- /dev/null +++ b/problems/functions/solution_fr.md @@ -0,0 +1,9 @@ +--- + +# OOOOOH DES BANANES + +Vous avez réussi ! Vous avez créé une fonction qui prend une entrée, la traite et renvoie une sortie. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/functions/solution_it.md b/problems/functions/solution_it.md new file mode 100644 index 00000000..c1597b7b --- /dev/null +++ b/problems/functions/solution_it.md @@ -0,0 +1,9 @@ +--- + +# UAOO BANANE + +Ce l'hai fatta! Hai creato una funzione che accetta un input, lo processa, e fornisce un output. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/functions/solution_nb-no.md b/problems/functions/solution_nb-no.md new file mode 100644 index 00000000..f7e3f257 --- /dev/null +++ b/problems/functions/solution_nb-no.md @@ -0,0 +1,9 @@ +--- + +# ÅÅÅÅHÅÅI BANANAS + +Du greide det! Du lagde en funksjon som tar data, prosesserer dataen og lager et resultat. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/functions/solution_nl.md b/problems/functions/solution_nl.md new file mode 100644 index 00000000..6aadc055 --- /dev/null +++ b/problems/functions/solution_nl.md @@ -0,0 +1,9 @@ +--- + +# WOOO BANANAS + +Het is je gelukt! Je hebt een function gemaakt die input ontvangt, deze input verwerkt, en output teruggeeft. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/functions/solution_pt-br.md b/problems/functions/solution_pt-br.md new file mode 100644 index 00000000..a3225ec9 --- /dev/null +++ b/problems/functions/solution_pt-br.md @@ -0,0 +1,9 @@ +--- + +# UHUUU! BANANAS!!! + +Você conseguiu! Você criou uma função que recebe uma entrada, processa aquela entrada, e devolve uma saída. + +Execute `javascripting` no console para escolher o próximo resultado. + +--- diff --git a/problems/functions/solution_ru.md b/problems/functions/solution_ru.md new file mode 100644 index 00000000..b66d3afe --- /dev/null +++ b/problems/functions/solution_ru.md @@ -0,0 +1,9 @@ +--- + +# УХ ТЫ, БАНАНЫ + +Вы сделали это! Вы создали функцию, которая берет входные данные, обрабатывает их и возвращает результат. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- \ No newline at end of file diff --git a/problems/functions/solution_uk.md b/problems/functions/solution_uk.md new file mode 100644 index 00000000..55677e9f --- /dev/null +++ b/problems/functions/solution_uk.md @@ -0,0 +1,9 @@ +--- + +# ВАУУУ БАНАНИ! + +Ви зробили це! Ви створили функцію, що приймає данні, обробляє їх та повертає результат. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/functions/solution_zh-tw.md b/problems/functions/solution_zh-tw.md new file mode 100644 index 00000000..4ced7182 --- /dev/null +++ b/problems/functions/solution_zh-tw.md @@ -0,0 +1,9 @@ +--- + +# 好吃的香蕉 + +你成功了!你建立了一個能將輸入進行處理並輸出的函式。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/if-statement/index.js b/problems/if-statement/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/if-statement/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/if-statement/problem.md b/problems/if-statement/problem.md index 1e1eb4c5..101e55e3 100644 --- a/problems/if-statement/problem.md +++ b/problems/if-statement/problem.md @@ -1,16 +1,12 @@ ---- - -# IF STATEMENT - Conditional statements are used to alter the control flow of a program, based on a specified boolean condition. A conditional statement looks like this: ```js if (n > 1) { - console.log('the variable n is greater than 1.'); + console.log('the variable n is greater than 1.') } else { - console.log('the variable n is less than or equal to 1.'); + console.log('the variable n is less than or equal to 1.') } ``` @@ -24,13 +20,13 @@ Create a file named `if-statement.js`. In that file, declare a variable named `fruit`. -Make the `fruit` variable reference the value **orange** with the type of **String**. +Make the `fruit` variable reference the string value **"orange"**. Then use `console.log()` to print "**The fruit name has more than five characters."** if the length of the value of `fruit` is greater than five. Otherwise, print "**The fruit name has five characters or less.**" Check to see if your program is correct by running this command: -`javascripting verify if-statement.js` - ---- +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_es.md b/problems/if-statement/problem_es.md index ddabc10f..4157f4bd 100644 --- a/problems/if-statement/problem_es.md +++ b/problems/if-statement/problem_es.md @@ -1,16 +1,12 @@ ---- - -# BLOQUE CONDICIONAL - Los bloques condicionales son utilizados, partiendo de una condición booleana específica, alterar el control de flujo de un programa. Un bloque condicional se parece a lo siguiente: ```js -if(n > 1) { - console.log('la variable n es mayor a 1.'); +if (n > 1) { + console.log('la variable n es mayor a 1.') } else { - console.log('la variable n es menor o igual a 1.'); + console.log('la variable n es menor o igual a 1.') } ``` @@ -24,13 +20,13 @@ Crea un archivo llamando `if-statement.js`. En ese archivo, declara una variabe llamada `fruit`. -Haz la variable `fruit` referenciar al valor **orange**, del tipo **String**. +Haz la variable `fruit` referenciar a la cadena de caracteres **"orange"**. Luego utiliza `console.log()` para imprimir a la terminal "**The fruit name has more than five characters."** si el length de la variable `fruit` es mayor a cinco. Imprime "**The fruit name has five characters or less.**" de lo contrario. Comprueba si tu programa funciona correctamente ejecutando el siguiente comando: -`javascripting verify if-statement.js` - ---- +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_fr.md b/problems/if-statement/problem_fr.md new file mode 100644 index 00000000..460f11d1 --- /dev/null +++ b/problems/if-statement/problem_fr.md @@ -0,0 +1,32 @@ +Les instructions conditionnelles servent à changer le flux d'exécution d'un programme selon des conditions booléennes spécifiques. + +Une instruction conditionnelle ressemble à ça : + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +Dans les parenthèses vous devez entrer une expression logique, ce qui veut dire que le résultat de l'instruction est soit vrai ( `true` ) soit faux ( `false` ). + +Le bloc `else` est optionnel et contient le code qui sera exécuté si la condition est fausse. + +## Le défi : + +Créez un fichier nommé `instruction-conditionnelle.js`. + +Dans ce fichier, déclarez une variable `fruit`. + +Assignez à la variable `fruit` la chaîne de caractères ***"orange"***. + +Utilisez ensuite `console.log()` pour afficher **« The fruit name has more than five characters. »** si la longueur du contenu de la variable `fruit` est supérieure à cinq. +Sinon, affichez **« The fruit name has five characters or less. »** + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify instruction-conditionnelle.js +``` diff --git a/problems/if-statement/problem_it.md b/problems/if-statement/problem_it.md new file mode 100644 index 00000000..32a58566 --- /dev/null +++ b/problems/if-statement/problem_it.md @@ -0,0 +1,32 @@ +Le istruzioni condizionali sono usate per alterare il flusso di controllo di un programma, in base ad una specifica condizione booleana. + +Un'istruzione condizionale appare come segue: + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +Dentro le parentesi devi includere un'istruzione logica, nel senso che il risultato dell'istruzione deve essere vero oppure falso. + +Il blocco `else` è opzionale e contiene del codice che sarà eseguito se la condizione è falsa. + +## La sfida: + +Crea un file dal nome `if-statement.js`. + +In questo file, dichiara una variabile chiamata `fruit`. + +Fa' in modo che la variabile `fruit` referenzi la stringa **"orange"**. + +Quindi usa `console.log()` per stampare "**The fruit name has more than five characters."** se la lunghezza del valore di `fruit` è maggiore di cinque. +Altrimenti, stampa "**The fruit name has five characters or less.**" + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_ja.md b/problems/if-statement/problem_ja.md index 6c80a21e..82e8b746 100644 --- a/problems/if-statement/problem_ja.md +++ b/problems/if-statement/problem_ja.md @@ -1,16 +1,12 @@ ---- - -# if 文 - 条件文を使って、次に実行する文を変更します。プログラムの流れを変更できます。条件は真理値で指定します。 たとえば... ```js if (n > 1) { - console.log('the variable n is greater than 1.'); + console.log('the variable n is greater than 1.') } else { - console.log('the variable n is less than or equal to 1.'); + console.log('the variable n is less than or equal to 1.') } ``` @@ -31,6 +27,6 @@ if (n > 1) { 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify if-statement.js` - ---- +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_ko.md b/problems/if-statement/problem_ko.md index ee9fd968..079f933d 100644 --- a/problems/if-statement/problem_ko.md +++ b/problems/if-statement/problem_ko.md @@ -1,16 +1,12 @@ ---- - -# IF 구문 - 지정된 조건을 기반으로, 조건문은 프로그램의 흐름 제어에 사용됩니다. 조건문은 이렇습니다. ```js if (n > 1) { - console.log('the variable n is greater than 1.'); + console.log('the variable n is greater than 1.') } else { - console.log('the variable n is less than or equal to 1.'); + console.log('the variable n is less than or equal to 1.') } ``` @@ -30,6 +26,6 @@ else 블록은 생략 가능하며 구문이 false일 경우 실행될 코드가 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify if-statement.js` - ---- +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_nb-no.md b/problems/if-statement/problem_nb-no.md new file mode 100644 index 00000000..8c0c150f --- /dev/null +++ b/problems/if-statement/problem_nb-no.md @@ -0,0 +1,32 @@ +En beslutning brukes for å endre kontrollflyten til et program, basert på en valgt betingelse. + +En beslutning ser slik ut: + +```js +if (n > 1) { + console.log('variablen n er større enn 1.') +} else { + console.log('variablen n er mindre eller lik 1.') +} +``` + +På innsiden av parantesene må du skrive et logisk uttrykk, det vil si et resultat av et uttrykk som enten er sant eller galt. + +else delen av en beslutning er valgfritt og inneholder den koden som vil kjøres dersom uttrykket er galt. + +## Oppgaven: + +Lag en fil som heter `if-statement.js`. + +Definer en variabel med navnet `fruit` i den filen. + +Lag `fruit` variablen slik at den referer verdien **orange** av typen **String**. + +Bruk deretter `console.log()` til å skrive ut "**The fruit name has more than five characters.**" om lengden av verdien til `fruit` er større enn 5. +Hvis ikke, skriv ut "**The fruit name has five characters or less.**" til skjermen. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_nl.md b/problems/if-statement/problem_nl.md new file mode 100755 index 00000000..44dd4434 --- /dev/null +++ b/problems/if-statement/problem_nl.md @@ -0,0 +1,34 @@ +Conditional statements worden gebruikt om de flow van een programma aan te passen, afhankelijk van een boolean voorwaarde. + +Een conditional statement ziet er zo uit: + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +Tussen de haakjes moet je een logische test schrijven, dit betekent dat de logische test of true (waar) is, of false (niet waar). + +Het else block is optioneel en bevat de code die uitgevoerd wordt als de logische test *false* is. + +## De uitdaging: + +Maak een nieuw bestand met de naam `if-statement.js`. + +Declareer in dit bestand een nieuwe variabele met de naam `fruit`. + +Laat de variabele `fruit` verwijzen naar de string **"orange"**. + +Gebruik nu `console.log()`. + +Als de lengte van de string `fruit` groter is dan vijf print je "**The fruit name has more than five characters."** naar de console. +Anders print je "**The fruit name has five characters or less.**" naar de console. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_pt-br.md b/problems/if-statement/problem_pt-br.md new file mode 100644 index 00000000..5f391931 --- /dev/null +++ b/problems/if-statement/problem_pt-br.md @@ -0,0 +1,32 @@ +Instruções condicionais são usadas para alterar o controle de fluxo de um programa, baseado em uma condição de verdadeiro ou falso. + +Uma instrução condicional é mais ou menos assim: + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +Dentro dos parênteses você deve informar uma instrução de lógica, com a idéia de que o resultado seja `true` ou `false`. + +O bloco `else` é opcional e contém o código que será executado caso a instrução resulte em false. + +## Desafio: + +Crie uma arquivo chamado `if-statement.js`. + +No arquivo criado, declare uma variável chamada `fruit`. + +Faça a variável `fruit` referenciar a cadeia de caracteres **orange**. + +Depois use o `console.log()` para imprimir "**The fruit name has more than five characters."** se o tamanho do valor da variável `fruit` é maior do que cinco. +Caso contrário, imprima "**The fruit name has five characters or less.**" + +Verifique se o seu programa está correto executando o comando: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_ru.md b/problems/if-statement/problem_ru.md new file mode 100644 index 00000000..55a561e6 --- /dev/null +++ b/problems/if-statement/problem_ru.md @@ -0,0 +1,32 @@ +Условные выражения используются для управления потоком выполнения программы, основываясь на определенном логическом условии. + +Условное выражение выглядит следующим образом: + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +Внутри скобок должно быть логическое утверждение, результатом которого является либо истина, либо ложь. + +Блок else является необязательным и содержит код, который выполнится, если результатом логического утверждения будет ложь. + +## Условие задачи: + +Создайте файл `if-statement.js`. + +В этом файле объявите переменную `fruit`. + +Присвойте переменной `fruit` значение **orange**, которое принадлежит к типу данных **String**. + +Затем используйте выражение `console.log()` чтобы вывести в терминал "**The fruit name has more than five characters.**" если длина строки в переменной `fruit` больше пяти. +В ином случае выведите в терминал "**The fruit name has five characters or less.**" + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_uk.md b/problems/if-statement/problem_uk.md new file mode 100644 index 00000000..becf6868 --- /dev/null +++ b/problems/if-statement/problem_uk.md @@ -0,0 +1,32 @@ +Умовні оператори викоритовують для контролю ходу виконання програми, в залежності від спеціальних булевих виразів (умов). + +Умовні оператори виглядають якось так: + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +Всередині круглих дужок має бути логічний вираз (умова). Це означає, що результат виразу має бути істиним (true) або хибним (false). + +Блок else є опціональним і містить код, що буде виконаний, якщо логічний вираз (умова) буде хибною (false). + +## Завдання: + +Створити файл `if-statement.js`. + +У цьому файлі оголосити змінну `fruit`. + +Зробити змінну `fruit` рівною значенню **orange** з типом **String (Рядок)**. + +Тоді використайте `console.log()`, щоб вивести "**The fruit name has more than five characters."**, якщо довжина значення `fruit` є більшою за 5. +В іншому випадку, виведіть "**The fruit name has five characters or less.**" + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_zh-cn.md b/problems/if-statement/problem_zh-cn.md index cc6dc242..e21076f2 100644 --- a/problems/if-statement/problem_zh-cn.md +++ b/problems/if-statement/problem_zh-cn.md @@ -1,16 +1,12 @@ ---- - -# IF 语句 - 条件语句基于一个特定的布尔值(即要么为真要么为假的值)来改变程序的控制流。 条件语句长得像下面这样: ```js if (n > 1) { - console.log('the variable n is greater than 1.'); + console.log('the variable n is greater than 1.') } else { - console.log('the variable n is less than or equal to 1.'); + console.log('the variable n is less than or equal to 1.') } ``` @@ -30,6 +26,6 @@ if (n > 1) { 运行下面的命令检查你的程序是否正确: -`javascripting verify if-statement.js` - ---- +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/problem_zh-tw.md b/problems/if-statement/problem_zh-tw.md new file mode 100644 index 00000000..84010be0 --- /dev/null +++ b/problems/if-statement/problem_zh-tw.md @@ -0,0 +1,31 @@ +條件語句基於一個特定的布林(Boolean)值來改變程序的流程。 + +條件語句長得像下面這樣: + +```js +if (n > 1) { + console.log('the variable n is greater than 1.') +} else { + console.log('the variable n is less than or equal to 1.') +} +``` + +在括號中你必須輸入一個邏輯判斷語句,這個邏輯判斷語句的結果不是true(真)就是false(假)。 + +`else` 語句區塊是可選的,包含了一旦邏輯語句結果為false時需要被執行的程式碼。 + +## 挑戰: + +建立一個名為 `if-statement.js` 的檔案。 + +在該檔案中,宣告一個名為 `fruit` 的變數。 + +給 `fruit` 變數賦予 **字串** 型別的值 **orange**。 + +接下來要使用 `console.log()`。如果 `fruit` 值的長度大於五,印出 "**The fruit name has more than five characters.**";否則就印出 "**The fruit name has five characters or less.**" + +執行下面的命令檢查你撰寫的程式是否正確: + +```bash +javascripting verify if-statement.js +``` diff --git a/problems/if-statement/solution_es.md b/problems/if-statement/solution_es.md index fffa0e48..80982520 100644 --- a/problems/if-statement/solution_es.md +++ b/problems/if-statement/solution_es.md @@ -2,7 +2,7 @@ # MAESTRO CONDICIONAL -Lo haz hecho! La string `naranja` tiene más de cinco caracteres. +Lo haz hecho! El string `orange` tiene más de cinco caracteres. Preparate para practicar **for loops** en el próximo ejercicio! diff --git a/problems/if-statement/solution_fr.md b/problems/if-statement/solution_fr.md new file mode 100644 index 00000000..8f688d75 --- /dev/null +++ b/problems/if-statement/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# MAÎTRE DES CONDITIONS + +Vous avez réussi ! La chaîne de caractères `orange` a plus de cinq caractères. + +Préparez vous pour les **boucles for** qui arrivent ensuite ! + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/if-statement/solution_it.md b/problems/if-statement/solution_it.md new file mode 100644 index 00000000..63d16e2c --- /dev/null +++ b/problems/if-statement/solution_it.md @@ -0,0 +1,11 @@ +--- + +# ESPERTO DEI CONDIZIONALI + +Ce l'hai fatta! La stringa `orange` ha più di cinque caratteri. + +Preparati ad affrontare i **cicli for** nel prossimo esercizio! + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/if-statement/solution_nb-no.md b/problems/if-statement/solution_nb-no.md new file mode 100644 index 00000000..5cc510d4 --- /dev/null +++ b/problems/if-statement/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# BESLUTNINGSMESTERN + +Det fikk du til! Stringen `orange` har mer enn 5 bokstaver. + +Gjør deg klar til prøve **for løkken** i neste oppgave! + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/if-statement/solution_nl.md b/problems/if-statement/solution_nl.md new file mode 100644 index 00000000..ca7441c9 --- /dev/null +++ b/problems/if-statement/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# MASTER VAN CONDITIONALS + +You got it! De string `orange` heeft meer dan vijf characters. + +Zorg dat je klaar zit om met **for loops** aan de slag te gaan! + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/if-statement/solution_pt-br.md b/problems/if-statement/solution_pt-br.md new file mode 100644 index 00000000..516262b1 --- /dev/null +++ b/problems/if-statement/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# MESTRE DAS CONDICIONAIS! + +Você entendeu a coisa toda! A string `orange` tem mais do que cinco caracteres. + +Se prepare para **fazer loops com for**! + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/if-statement/solution_ru.md b/problems/if-statement/solution_ru.md new file mode 100644 index 00000000..17f0ec63 --- /dev/null +++ b/problems/if-statement/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# МАСТЕР УСЛОВНЫХ ВЫРАЖЕНИЙ + +Точно! В строке `orange` больше пяти символов. + +Далее приготовьтесь к **циклам for**! + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- \ No newline at end of file diff --git a/problems/if-statement/solution_uk.md b/problems/if-statement/solution_uk.md new file mode 100644 index 00000000..620ca482 --- /dev/null +++ b/problems/if-statement/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# МАЙСТЕР УМОВНИХ ОПЕРАТОРІВ + +Вам вдалось! Рядок `orange` місти більш ніж 5 символів. + +Пригодуйтесь до **циклу for**! + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/if-statement/solution_zh-tw.md b/problems/if-statement/solution_zh-tw.md new file mode 100644 index 00000000..830e5cf2 --- /dev/null +++ b/problems/if-statement/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 真是一個條件式大師 + +結果正確!字串 `orange` 的長度多於五個字元。 + +準備好了嗎?讓我們繼續學習 **for 迴圈** 吧! + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/introduction/index.js b/problems/introduction/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/introduction/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/introduction/problem.md b/problems/introduction/problem.md index bdf3adcd..aadcb19d 100644 --- a/problems/introduction/problem.md +++ b/problems/introduction/problem.md @@ -1,33 +1,44 @@ ---- -# INTRODUCTION - To keep things organized, let's create a folder for this workshop. Run this command to make a directory called `javascripting` (or something else if you like): -`mkdir javascripting` +```bash +mkdir javascripting +``` Change directory into the `javascripting` folder: -`cd javascripting` +```bash +cd javascripting +``` Create a file named `introduction.js`: -`touch introduction.js` or if you're on windows, `type NUL > introduction.js` (`type` is part of the command!) +```bash +touch introduction.js +``` + +Or if you're on Windows: +```bash +type NUL > introduction.js +``` +(`type` is part of the command!) Open the file in your favorite editor, and add this text: ```js -console.log('hello'); +console.log('hello') ``` Save the file, then check to see if your program is correct by running this command: -`javascripting verify introduction.js` - ---- - +```bash +javascripting verify introduction.js +``` +By the way, throughout this tutorial, you can give the file you work with any name you like, so if you want to use something like `catsAreAwesome.js` file for every exercise, you can do that. Just make sure to run: -> **Need help?** View the README for this workshop: http://github.com/sethvincent/javascripting +```bash +javascripting verify catsAreAwesome.js +``` diff --git a/problems/introduction/problem_es.md b/problems/introduction/problem_es.md index f6ac95e1..8e0a2cae 100644 --- a/problems/introduction/problem_es.md +++ b/problems/introduction/problem_es.md @@ -1,31 +1,37 @@ ---- -# INTRODUCCIÓN - Para mantener el orden, procederemos a crear una carpeta para este workshop. Ejecuta el siguiente comando, cambiando el nombre de la carpeta o colocando el path que necesites: -`mkdir javascripting` +```bash +mkdir javascripting +``` Cambia de directorio a la carpeta que acabas de crear: -`cd javascripting` +```bash +cd javascripting +``` Crea un archivo llamado `introduction.js` utilizando: -`touch introduction.js`, o si utilizas Windows `type NUL > introduction.js` (`type` es parte del comando!) +```bash +touch introduction.js +``` +, o si utilizas Windows +```bash +type NUL > introduction.js +``` +(`type` es parte del comando!) Agrega el siguiente texto al archivo: ```js -console.log('hello'); +console.log('hello') ``` Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify introduction.js` - ---- - +```bash +javascripting verify introduction.js +``` -> **Necesitas ayuda?** Vista el README de este workshop: github.com/sethvincent/javascripting diff --git a/problems/introduction/problem_fr.md b/problems/introduction/problem_fr.md new file mode 100644 index 00000000..27153e78 --- /dev/null +++ b/problems/introduction/problem_fr.md @@ -0,0 +1,44 @@ +Pour rester organisé, créons un dossier pour ce TP. + +Exécutez cette commande pour créer un dossier nommé `javascripting` (ou quelque chose d'autre si vous préférez) : + +```bash +mkdir javascripting +``` + +Allez dans le dossier `javascripting` avec cette commande : + +```bash +cd javascripting +``` + +Créez un fichier nommé `introduction.js` : + +```bash +touch introduction.js +``` + +ou si vous êtes sur Windows : +```bash +type NUL > introduction.js +``` +( `type` fait partie de la commande ! ) + +Ouvrez le fichier dans votre éditeur favori, et ajoutez ce texte : + +```js +console.log('hello') +``` + +Sauvegardez le fichier, puis vérifiez si votre programme s'exécute correctement avec cette commande : + +```bash +javascripting verify introduction.js +``` + +Au passage, tout au long de ce tutoriel, vous pouvez donner nommer les fichiers comme bon vous semble, donc si vous voulez utiliser quelque chose comme `lesChatsSontGeniaux.js` comme nom de fichier pour tous les exercices, vous pouvez. Assurez-vous juste d'exécuter : + +```bash +javascripting verify lesChatsSontGeniaux.js +``` + diff --git a/problems/introduction/problem_it.md b/problems/introduction/problem_it.md new file mode 100644 index 00000000..4db1108a --- /dev/null +++ b/problems/introduction/problem_it.md @@ -0,0 +1,43 @@ +Per mantenere le cose organizzate, creiamo una cartella per questo workshop. + +Esegui questo comando per creare una directory chiamata `javascripting` (o qualcos'altro a tuo piacere): + +```bash +mkdir javascripting +``` + +Cambia la directory di lavoro con la directory `javascripting`: + +```bash +cd javascripting +``` + +Crea un file dal nome `introduction.js`: + +```bash +touch introduction.js +``` + +oppure, se ti trovi su Windows, +```bash +type NUL > introduction.js +``` +(`type` è parte del comando!) + +Apri il file nel tuo editor preferito, e aggiungi questo testo: + +```js +console.log('hello') +``` + +Salva il file, quindi verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify introduction.js +``` + +Tra parentesi, lungo il corso di questa guida, puoi dare al file con cui stai lavorando il nome che desideri, quindi se vuoi usare un nome di file come `catsAreAwesome.js` per ciascun esercizio, puoi farlo tranquillamente. Assicurati tuttavia di eseguire il file giusto: + +```bash +javascripting verify catsAreAwesome.js +``` diff --git a/problems/introduction/problem_ja.md b/problems/introduction/problem_ja.md index 04ed515a..9def489b 100644 --- a/problems/introduction/problem_ja.md +++ b/problems/introduction/problem_ja.md @@ -1,32 +1,33 @@ ---- -# INTRODUCTION - このワークショップで使うディレクトリを作りましょう。 次のコマンドを実行して、`javascripting` ディレクトリを作ります。 -`mkdir javascripting` +```bash +mkdir javascripting +``` `javascripting` ディレクトリに移動しましょう。 -`cd javascripting` +```bash +cd javascripting +``` 次のコマンドで `introduction.js` ファイルを作成します。 -`touch introduction.js` (Windowsを使っているのであれば `type NUL > introduction.js`) +```bash +touch introduction.js +``` + (Windowsを使っているのであれば `type NUL > introduction.js`) お好みのエディタでファイルを開きます。次の文を書き足しましょう。 ```js -console.log('hello'); +console.log('hello') ``` ファイルを保存します。次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify introduction.js` - ---- - - +```bash +javascripting verify introduction.js +``` -> **ヘルプが必要ですか??** このワークショップのREADMEを読んでください。 : http://github.com/ledsun/javascripting diff --git a/problems/introduction/problem_ko.md b/problems/introduction/problem_ko.md index eb10a92e..c9425698 100644 --- a/problems/introduction/problem_ko.md +++ b/problems/introduction/problem_ko.md @@ -1,32 +1,45 @@ ---- -# 소개 - 정돈을 위해 이 워크숍을 위한 폴더를 만듭시다. -이 명령어를 실행해 `javascripting`이라는 디렉터리(다른 이름이어도 됩니다)를 만드세요. +```bash +mkdir javascripting +``` + +위 명령어를 실행해 `javascripting`이라는 디렉터리(다른 이름이어도 됩니다)를 만드세요. + +```bash +cd javascripting +``` + +을 통해 `javascripting` 폴더 안으로 디렉터리를 변경하세요. -`mkdir javascripting` +```bash +touch introduction.js +``` -`javascripting` 폴더 안으로 디렉터리를 변경하세요. +를 입력해 `introduction.js`이라는 파일을 만드세요. -`cd javascripting` +윈도우라면 -`introduction.js`이라는 파일을 만드세요. +```bash +type NUL > introduction.js +``` -`touch introduction.js` 윈도우라면 `type NUL > introduction.js`(`type`도 명령어의 일부입니다!) +(`type`도 명령어의 일부입니다!)로 만들 수 있습니다. 좋아하는 편집기에서 파일을 열고 다음 내용을 넣으세요. ```js -console.log('hello'); +console.log('hello') ``` 파일을 저장하고 프로그램이 올바른지 다음 명령어를 실행해 확인하세요. -`javascripting verify introduction.js` - ---- - +```bash +javascripting verify introduction.js +``` +하지만 튜토리얼 내내 편한 이름을 사용하셔도 됩니다. 모든 연습 문제에 `catsAreAwesome.js` 같은 이름을 사용하시고 싶다면, 그럴 수 있습니다. 그냥 다음 명령어를 실행해 확인하세요. -> **도움이 필요하신가요?** 이 워크숍의 README를 확인하세요. http://github.com/sethvincent/javascripting +```bash +javascripting verify catsAreAwesome.js +``` diff --git a/problems/introduction/problem_nb-no.md b/problems/introduction/problem_nb-no.md new file mode 100644 index 00000000..44cbb8b8 --- /dev/null +++ b/problems/introduction/problem_nb-no.md @@ -0,0 +1,37 @@ +For å holde ting organisert kan vi lage en ny katalog for denne workshopen. + +Kjør denne kommandoen for å lage en katalog som heter `javascripting` (eller noe annet om du ønsker): + +```bash +mkdir javascripting +``` + +Bytt til `javascripting` katalogen: + +```bash +cd javascripting +``` + +Lag en fil som heter `introduction.js`: + +```bash +touch introduction.js +``` + eller hvis du bruker Windows, + +```bash +type NUL > introduction.js +``` +(`type` er en del av kommandoen!) + +Åpne filen i din favoritt editor og legg til følgende tekst: + +```js +console.log('hello') +``` + +Lagre filen, deretter sjekker du om programmet er korrekt ved å kjøre følgende kommando: + +```bash +javascripting verify introduction.js +``` diff --git a/problems/introduction/problem_nl.md b/problems/introduction/problem_nl.md new file mode 100755 index 00000000..bed9c0f8 --- /dev/null +++ b/problems/introduction/problem_nl.md @@ -0,0 +1,44 @@ +Om alles overzichtelijk te houden, maken we een map voor deze workshop. + +Voer dit commando uit om een folder te maken met de naam `javascripting` (of een naam die je zelf kiest): + +```bash +mkdir javascripting +``` + +Ga nu naar de `javascripting` folder: + +```bash +cd javascripting +``` + +Maak een nieuw bestand met de naam `introduction.js`: + +```bash +touch introduction.js +``` + +Of, als je op Windows werkt: +```bash +type NUL > introduction.js +``` +(`type` is deel van het commando!) + +Open thet bestand in je favoriete editor en voeg deze tekst toe: + +```js +console.log('hello') +``` + +Bewaar het bestand en controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify introduction.js +``` + +Trouwens, in deze tutorial kun je het bestand waarmee je werkt elke naam geven die je wilt, dus als je iets als `catsAreAwesome.js` voor elke oefening wilt gebruiken, kun je dat doen. Zorg ervoor dat je dan dit commando gebruikt: + +```bash +javascripting verify catsAreAwesome.js +``` + diff --git a/problems/introduction/problem_pt-br.md b/problems/introduction/problem_pt-br.md new file mode 100644 index 00000000..85ce3335 --- /dev/null +++ b/problems/introduction/problem_pt-br.md @@ -0,0 +1,38 @@ +Para manter uma boa organização, vamos criar uma pasta para este workshop. + +Execute este comando para criar um diretório chamado `javascripting`: + +```bash +mkdir javascripting +``` + +Mude o diretório do console para a pasta que você acabou de criar: + +```bash +cd javascripting +``` + +Crie um arquivo chamado `introduction.js`: + +```bash +touch introduction.js +``` + ou se você estiver no Windows execute o comando: + +```bash +type NUL > introduction.js +``` + +Abra o arquivo no seu editor favorito, e adicione este texto: + +```js +console.log('hello') +``` + +Salve o arquivo, e então verifique se o seu programa está correto executando este comando: + +```bash +javascripting verify introduction.js +``` + + diff --git a/problems/introduction/problem_ru.md b/problems/introduction/problem_ru.md new file mode 100644 index 00000000..984fc782 --- /dev/null +++ b/problems/introduction/problem_ru.md @@ -0,0 +1,43 @@ +Для поддержания порядка давайте создадим для этого воркшопа отдельную папку. + +Выполните в терминале эту команду, чтобы создать папку под названием `javascripting` (можете использовать другое название, если хотите): + +```bash +mkdir javascripting +``` + +Перейдите в папку `javascripting`: + +```bash +cd javascripting +``` + +Создайте файл `introduction.js`: + +```bash +touch introduction.js +``` + +или, если у вас Windows, +```bash +type NUL > introduction.js +``` +(`type` это тоже часть команды!) + +Откройте этот файл в вашем любимом редакторе и добавьте следующий текст: + +```js +console.log('hello') +``` + +Сохраните файл, и, чтобы проверить что ваша программа работает правильно, запустите в терминале следующую команду: + +```bash +javascripting verify introduction.js +``` + +Кстати, работая с практическими заданиями, можете называть файлы как вам нравится, если например для каждого упражнения вы хотите использовать файл с именем `catsAreAwesome.js`, полный вперёд! Просто удостоверьтесь, что вы запускаете в терминале: + +```bash +javascripting verify catsAreAwesome.js +``` diff --git a/problems/introduction/problem_uk.md b/problems/introduction/problem_uk.md new file mode 100644 index 00000000..2083c3db --- /dev/null +++ b/problems/introduction/problem_uk.md @@ -0,0 +1,42 @@ +Давайте створемо окрему директорію для цього воркшопу, щоб зберігати чистоту в наших файлах. + +Запустіть цю команду, щоб створити директорію, яка називатиметься `javascripting` (або будь-як інакше): + +```bash +mkdir javascripting +``` + +Перейдіть в директорію `javascripting` командою: + +```bash +cd javascripting +``` + +Створіть файл `introduction.js`: + +```bash +touch introduction.js +``` + або якщо ви на Windows, + +```bash +type NUL > introduction.js +``` + (`type` це частина команди!) + +Відкрийте файл у вашому улюбленому текстовому редакторі та додайте цей текст: + +```js +console.log('hello') +``` +Збережіть файл, а потім перевірте вашу програму запустивши команду: + +```bash +javascripting verify introduction.js +``` + +До речі, на процязі цього курсу ви можете можете називати файли так, як вам подобається. Якщо ви хочете назвати файл ім’ям `catsAreAwesome.js` для кожної вправи, то зробіть це. Лише не забудьте потім перевірити його: + +```bash +javascripting verify catsAreAwesome.js +``` diff --git a/problems/introduction/problem_zh-cn.md b/problems/introduction/problem_zh-cn.md index 38eb51c9..6311c4f9 100644 --- a/problems/introduction/problem_zh-cn.md +++ b/problems/introduction/problem_zh-cn.md @@ -1,15 +1,16 @@ ---- -# 入门 - 为了让工作环境整洁有序,我们首先来创建一个文件夹。 运行下面的这段命令来创建一个名为 `javascripting` 的文件夹(你也可以使用你喜欢的其它名字): -`mkdir javascripting` +```bash +mkdir javascripting +``` 进入 `javascripting` 文件夹: -`cd javascripting` +```bash +cd javascripting +``` 创建一个名为 `introduction.js` 的文件: @@ -18,16 +19,11 @@ 使用你最喜欢的编辑器,打开这个文件,然后将下面这行加入到文件中: ```js -console.log('hello'); +console.log('hello') ``` 保存文件,运行下面的命令来检查你的程序是否正确: -`javascripting verify introduction.js` - ---- - - - -> **需要帮助?** 查看本教程的 README 文件:http://github.com/sethvincent/javascripting - +```bash +javascripting verify introduction.js +``` diff --git a/problems/introduction/problem_zh-tw.md b/problems/introduction/problem_zh-tw.md new file mode 100644 index 00000000..ff7f0d36 --- /dev/null +++ b/problems/introduction/problem_zh-tw.md @@ -0,0 +1,29 @@ +為了讓工作環境井然有序,我們首先來建立一個新資料夾。 + +執行下面的這段命令來建立一個名為 `javascripting` 的資料夾(當然你也可以使用其他你喜歡的名字): + +```bash +mkdir javascripting +``` + +進入 `javascripting` 資料夾: + +```bash +cd javascripting +``` + +建立一個名為 `introduction.js` 的檔案: + +非 Windows 用戶,請執行 `touch introduction.js`;Windows 用戶,請執行 `type NUL > introduction.js`(注意,`type` 也是這個命令的一部分!) + +使用你最喜歡的編輯器,打開這個檔案,然後將下面這行程式碼加入到檔案中: + +```js +console.log('hello') +``` + +儲存檔案,執行下面的命令來檢查你的程式是否正確: + +```bash +javascripting verify introduction.js +``` diff --git a/problems/introduction/solution.md b/problems/introduction/solution.md index d91cba55..9c72771c 100644 --- a/problems/introduction/solution.md +++ b/problems/introduction/solution.md @@ -7,7 +7,7 @@ Anything between the parentheses of `console.log()` are printed to the terminal. So this: ```js -console.log('hello'); +console.log('hello') ``` prints `hello` to the terminal. @@ -17,5 +17,3 @@ Currently we are printing a **string** of characters to the terminal: `hello`. In the next challenge we focus on learning about **variables**. Run `javascripting` in the console to choose the next challenge. - ---- diff --git a/problems/introduction/solution_es.md b/problems/introduction/solution_es.md index df824fb6..d5bfbf08 100644 --- a/problems/introduction/solution_es.md +++ b/problems/introduction/solution_es.md @@ -7,7 +7,7 @@ Todo lo que esté dentro de los paréntesis de `console.log()` será impreso a l Entonces esto: ```js -console.log('hola mundo'); +console.log('hola mundo') ``` imprime `hola mundo` a la terminal. @@ -17,5 +17,3 @@ En particular, estamos imprimiendo una **string** o cadena de caracteres a la te En el siguiente ejercicio nos concentramos en aprender más acerca de **strings**. Ejecuta `javascripting` en la consola para seleccionar el siguiente ejercicio. - ---- diff --git a/problems/introduction/solution_fr.md b/problems/introduction/solution_fr.md new file mode 100644 index 00000000..92c20274 --- /dev/null +++ b/problems/introduction/solution_fr.md @@ -0,0 +1,19 @@ +--- + +# VOUS AVEZ RÉUSSI ! + +Tout ce qui est entre les parenthèses de `console.log()` est affiché dans le terminal. + +Donc : + +```js +console.log('hello') +``` + +affiche `hello` dans le terminal. + +Pour le moment nous affichons une **chaîne de caractères** dans le terminal : `hello`. + +Dans le prochain défi, nous allons nous focaliser sur l'apprentissage des **variables**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. diff --git a/problems/introduction/solution_it.md b/problems/introduction/solution_it.md new file mode 100644 index 00000000..f4d8d23b --- /dev/null +++ b/problems/introduction/solution_it.md @@ -0,0 +1,19 @@ +--- + +# CE L'HAI FATTA! + +Qualsiasi cosa contenuta tra le parentesi `console.log()` viene stampata sul terminale. + +Quindi questo: + +```js +console.log('hello') +``` + +stampa `hello` sul terminal. + +Al momento stiamo stampando una **stringa** di caratteri sul terminale: `hello`. + +Nella prossima sfida ci occuperemo di apprendere sulle **variabili**. + +Esegui `javascripting` nella console per scegliere la prossima sfida. diff --git a/problems/introduction/solution_ja.md b/problems/introduction/solution_ja.md index 2901e9d8..93300ec8 100644 --- a/problems/introduction/solution_ja.md +++ b/problems/introduction/solution_ja.md @@ -7,7 +7,7 @@ たとえば... ```js -console.log('hello'); +console.log('hello') ``` ターミナルに `hello` を表示します。 @@ -17,5 +17,3 @@ console.log('hello'); 次の課題では**変数**を学びます。 コンソールで `javascripting` コマンドを実行します。次の課題を選択しましょう。 - ---- diff --git a/problems/introduction/solution_ko.md b/problems/introduction/solution_ko.md index affae2d3..915d0226 100644 --- a/problems/introduction/solution_ko.md +++ b/problems/introduction/solution_ko.md @@ -7,7 +7,7 @@ 그래서 ```js -console.log('hello'); +console.log('hello') ``` 는 `hello`를 터미널에 출력합니다. @@ -17,5 +17,3 @@ console.log('hello'); 다음 과제에서는 **변수**를 배우는 데 초점을 맞추겠습니다. 다음 과제로 가시려면 콘솔에서 `javascripting`을 실행하세요. - ---- diff --git a/problems/introduction/solution_nb-no.md b/problems/introduction/solution_nb-no.md new file mode 100644 index 00000000..e3dec3cb --- /dev/null +++ b/problems/introduction/solution_nb-no.md @@ -0,0 +1,19 @@ +--- + +# DU GREIDE DET! + +Alt mellom parantesene i `console.log()` skrives ut til skjermen. + +Det vil si: + +```js +console.log('hello') +``` + +skriver ut `hello` til skjermen. + +For øyeblikket skriver vi ut en **string** av bokstaver til skjermen: `hello`. + +I den neste oppgaven skal vi lære om **variabler**. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. diff --git a/problems/introduction/solution_nl.md b/problems/introduction/solution_nl.md new file mode 100644 index 00000000..a702676c --- /dev/null +++ b/problems/introduction/solution_nl.md @@ -0,0 +1,19 @@ +--- + +# HET IS JE GELUKT! + +Alles wat je tussen de haakjes van `console.log()` zet, wordt naar de console (terminal) geprint. + +Dus dit: + +```js +console.log('hallo') +``` + +print `hallo` naar de terminal. + +Nu printen we nog en **string** bestaande uit characters naar de terminal: `hallo`. + +In de volgende uitdaging gaan we leren over **variabele**. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. diff --git a/problems/introduction/solution_pt-br.md b/problems/introduction/solution_pt-br.md new file mode 100644 index 00000000..906bfe2c --- /dev/null +++ b/problems/introduction/solution_pt-br.md @@ -0,0 +1,19 @@ +--- + +# VOCÊ CONSEGUIU! + +Qualquer coisa entre os parênteses de `console.log()` é impresso no terminal. + +Então isto: + +```js +console.log('hello') +``` + +imprime `hello` no terminal. + +Atualmente estamos imprimindo uma **string** de caracteres para o terminal: `hello`. + +No próximo desafio vamos nos focar em aprender sobre **variáveis**. + +Execute `javascripting` no console para escolher o próximo desafio. diff --git a/problems/introduction/solution_ru.md b/problems/introduction/solution_ru.md new file mode 100644 index 00000000..3dd20bca --- /dev/null +++ b/problems/introduction/solution_ru.md @@ -0,0 +1,21 @@ +--- + +# ВЫ СДЕЛАЛИ ЭТО! + +Все, что находится внутри скобок выражения `console.log()`, выводится в терминал. + +Поэтому вот это выражение: + +```js +console.log('hello') +``` + +выведет в терминал `hello`. + +Т.е. мы печатаем в терминале **строку** символов: `hello`. + +В следующем задании мы сосредоточимся на изучении **переменных**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/introduction/solution_uk.md b/problems/introduction/solution_uk.md new file mode 100644 index 00000000..b2a05191 --- /dev/null +++ b/problems/introduction/solution_uk.md @@ -0,0 +1,19 @@ +--- + +# Ви зробили це! + +Будь-що між круглими дужками `console.log()` буде виведено до терміналу. + +Тому це: + +```js +console.log('hello') +``` + +виведе `hello` до терміналу. + +Зараз ми виводимо **рядок (string)** символів (characters) до терміналу: `hello`. + +В наступному завданні ми сфокусуємось на вивченні **змінних**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. diff --git a/problems/introduction/solution_zh-cn.md b/problems/introduction/solution_zh-cn.md index 5965d7c3..365aac07 100644 --- a/problems/introduction/solution_zh-cn.md +++ b/problems/introduction/solution_zh-cn.md @@ -7,7 +7,7 @@ 所以: ```js -console.log('hello'); +console.log('hello') ``` 打印出 `hello` 到你的终端。 @@ -17,5 +17,3 @@ console.log('hello'); 接下来的挑战里我们将学习到 **variables**,也就是**变量**。 运行 `javascripting` 并选择下一个挑战。 - ---- diff --git a/problems/introduction/solution_zh-tw.md b/problems/introduction/solution_zh-tw.md new file mode 100644 index 00000000..1f2b8e16 --- /dev/null +++ b/problems/introduction/solution_zh-tw.md @@ -0,0 +1,19 @@ +--- + +# 完成! + +任何於 `console.log()` 括號中的東西都將會被輸出到你的終端機(Terminal,於Windows下即命令提示字元)上。 + +所以: + +```js +console.log('hello') +``` + +會印出 `hello` 到你的終端機。 + +此刻,我們輸出的是一個 **string**,中文名為**字串**。 + +接下來的挑戰裡我們將學習到 **variables**,也就是**變數**。 + +運行 `javascripting` 並選擇下一個挑戰。 diff --git a/problems/looping-through-arrays/index.js b/problems/looping-through-arrays/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/looping-through-arrays/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/looping-through-arrays/problem.md b/problems/looping-through-arrays/problem.md index 6389c2ec..bb067aad 100644 --- a/problems/looping-through-arrays/problem.md +++ b/problems/looping-through-arrays/problem.md @@ -1,7 +1,3 @@ ---- - -# LOOPING THROUGH ARRAYS - For this challenge we will use a **for loop** to access and manipulate a list of values in an array. Accessing array values can be done using an integer. @@ -11,13 +7,13 @@ Each item in an array is identified by a number, starting at `0`. So in this array `hi` is identified by the number `1`: ```js -var greetings = ['hello', 'hi', 'good morning']; +const greetings = ['hello', 'hi', 'good morning'] ``` It can be accessed like this: ```js -greetings[1]; +greetings[1] ``` So inside a **for loop** we would use the `i` variable inside the square brackets instead of directly using an integer. @@ -29,7 +25,7 @@ Create a file named `looping-through-arrays.js`. In that file, define a variable named `pets` that references this array: ```js -['cat', 'dog', 'rat']; +['cat', 'dog', 'rat'] ``` Create a for loop that changes each string in the array so that they are plural. @@ -37,13 +33,13 @@ Create a for loop that changes each string in the array so that they are plural. You will use a statement like this inside the for loop: ```js -pets[i] = pets[i] + 's'; +pets[i] = pets[i] + 's' ``` After the for loop, use `console.log()` to print the `pets` array to the terminal. Check to see if your program is correct by running this command: -`javascripting verify looping-through-arrays.js` - ---- +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_es.md b/problems/looping-through-arrays/problem_es.md index 61d298b3..2f7b8758 100644 --- a/problems/looping-through-arrays/problem_es.md +++ b/problems/looping-through-arrays/problem_es.md @@ -1,7 +1,3 @@ ---- - -# RECORRIENDO ARRAYS - Para este ejercicio usaremos un bucle **for** para acceder y manipular una lista de valores en un array. Se puede acceder a los valores de un array utilizando un contador. @@ -13,12 +9,12 @@ Los índices comienzan desde el cero. Entonces en este array, el elemento `hi` es identificado por el número `1`: ```js -var greetings = ['hello', 'hi', 'good morning']; +const greetings = ['hello', 'hi', 'good morning'] ``` Puede ser accedido de la siguiente forma: ```js -greetings[1]; +greetings[1] ``` Entonces dentro de un bucle **for** utilizaremos la variable `ì` dentro de los corchetes. @@ -30,7 +26,7 @@ Crea un archivo llamando `looping-through-arrays.js`. En ese archivo, define una variable llamada `pets` que referencie este array: ```js -['cat', 'dog', 'rat']; +['cat', 'dog', 'rat'] ``` Crea un bucle for que cambie cada string en el array para que sean plurales. @@ -38,13 +34,13 @@ Crea un bucle for que cambie cada string en el array para que sean plurales. Usarás una sentencia parecida a la siguiente dentro del bucle: ```js -pets[i] = pets[i] + 's'; +pets[i] = pets[i] + 's' ``` Utiliza `console.log()` para imprimir el array `pets` a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify looping-through-arrays.js` - ---- +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_fr.md b/problems/looping-through-arrays/problem_fr.md new file mode 100644 index 00000000..96d77765 --- /dev/null +++ b/problems/looping-through-arrays/problem_fr.md @@ -0,0 +1,45 @@ +Pour ce défi nous utiliserons une **boucle for** pour manipuler une liste de valeurs dans un tableau. + +L'accès à des valeurs de tableaux peut être effectué en utilisant un nombre entier. + +Chaque élément du tableau est identifié par un nombre, commençant à `0`. + +Donc dans ce tableau, `hi` est identifié par le nombre `1` : + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +On peut y accéder comme ceci : + +```js +greetings[1] +``` + +Dans une **boucle for**, plutôt que d'indiquer directement l'index avec un nombre entier nous allons mettre la variable `i` entre les crochets. + +## Le défi : + +Créez un fichier nommé `iterer-dans-des-tableaux.js`. + +Dans ce fichier, définissez une variable nommée `pets` qui contient les valeurs suivantes : + +```js +['cat', 'dog', 'rat'] +``` + +Créez une boucle for qui modifie chaque chaîne de caractères dans le tableau pour les mettre au pluriel. + +Nous utiliserons une instruction similaire à celle-ci dans la boucle for : + +```js +pets[i] = pets[i] + 's' +``` + +Après la boucle for, utilisez `console.log()` pour afficher le tableau `pets` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify iterer-dans-des-tableaux.js +``` diff --git a/problems/looping-through-arrays/problem_it.md b/problems/looping-through-arrays/problem_it.md new file mode 100644 index 00000000..4d0746c5 --- /dev/null +++ b/problems/looping-through-arrays/problem_it.md @@ -0,0 +1,45 @@ +Per questa sfida useremo un **ciclo for** per accedere e manipolare una lista di valori in un array. + +L'accesso ai valori di un array si effettua attraverso un numero intero. + +Ciascun elemento di un array è identificato da un numero, a iniziare dallo `0`. + +Quindi in questo array `hi` è identificato dal numero `1`: + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +E può essere acceduto come segue: + +```js +greetings[1] +``` + +Quindi dentro un **ciclo for** useremmo la variabile `i` dentro le parentesi quadre anziché usare direttamente un intero. + +## La sfida: + +Crea un file dal nome `looping-through-arrays.js`. + +In questo file, definisci una variabile chiamata `pets` che referenzia questo array: + +```js +['cat', 'dog', 'rat'] +``` + +Crea un ciclo for che cambia ciascuna stringa dell'array nel suo plurale. + +Utilizzerai un'istruzione come questa all'interno del ciclo for: + +```js +pets[i] = pets[i] + 's' +``` + +Al termine del ciclo for, usa `console.log()` per stampare l'array `pets` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_ja.md b/problems/looping-through-arrays/problem_ja.md index 7e715702..ea9e0c5f 100644 --- a/problems/looping-through-arrays/problem_ja.md +++ b/problems/looping-through-arrays/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 配列をループする - この課題では、**forループ**を使用して、配列の中の値を取得したり変更したりします。 配列の値にアクセスするには、整数を使用します。 @@ -11,13 +7,13 @@ たとえば、次の配列内の `hi` は、数値 `1` で識別できます... ```js -var greetings = ['hello', 'hi', 'good morning']; +const greetings = ['hello', 'hi', 'good morning'] ``` 次のようにアクセスします... ```js -greetings[1]; +greetings[1] ``` **forループ**の中では、変数 `i` を角括弧の中に入れて使います。整数を直接使うことはありません。 @@ -30,7 +26,7 @@ greetings[1]; ファイルの中で、次の配列を表す、変数 `pets` を定義しましょう。 ```js -['cat', 'dog', 'rat']; +['cat', 'dog', 'rat'] ``` forループを作って、配列内の各文字列が複数形になるように変更します。 @@ -38,13 +34,13 @@ forループを作って、配列内の各文字列が複数形になるよう forループの中は次のようになるでしょう... ```js -pets[i] = pets[i] + 's'; +pets[i] = pets[i] + 's' ``` forループが終わったら、 `console.log()` を使って配列 `pets` をターミナルに表示しましょう。 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify looping-through-arrays.js` - ---- +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_ko.md b/problems/looping-through-arrays/problem_ko.md index f951a2e3..8e49946a 100644 --- a/problems/looping-through-arrays/problem_ko.md +++ b/problems/looping-through-arrays/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 배열을 루프하기 - 이 도전 과제에서는 **for 반복문**을 사용해 배열에 있는 값의 목록에 접근하고 조작하겠습니다. 배열 값에 접근하는 것은 정수를 사용해 할 수 있습니다. @@ -11,13 +7,13 @@ 그래서 이 배열의 `hi`는 숫자 `1`로 확인할 수 있습니다. ```js -var greetings = ['hello', 'hi', 'good morning']; +const greetings = ['hello', 'hi', 'good morning'] ``` 이렇게 접근할 수 있습니다. ```js -greetings[1]; +greetings[1] ``` **for 반복문** 안에서는 숫자 그대로 사용하지 않고 `i` 변수를 각괄호 안에서 사용합니다. @@ -29,7 +25,7 @@ greetings[1]; 이 파일 안에서 다음 배열을 참조하는 `pets`라는 이름의 변수를 선언합니다. ```js -['cat', 'dog', 'rat']; +['cat', 'dog', 'rat'] ``` for 반복문을 만들어 복수형이 되도록 각 문자열을 변경하세요. @@ -37,13 +33,13 @@ for 반복문을 만들어 복수형이 되도록 각 문자열을 변경하세 루프 안에서 이런 구문을 사용하시면 됩니다. ```js -pets[i] = pets[i] + 's'; +pets[i] = pets[i] + 's' ``` 루프 뒤에 `console.log()`로 `pets` 배열을 터미널에 출력하세요. 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify looping-through-arrays.js` - ---- +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_nb-no.md b/problems/looping-through-arrays/problem_nb-no.md new file mode 100644 index 00000000..d2acab3b --- /dev/null +++ b/problems/looping-through-arrays/problem_nb-no.md @@ -0,0 +1,45 @@ +I denne oppgaven skal vi bruke en **for løkke** til å lese og endre en liste av verdier i et array. + +Å lese verdier fra et array kan gjøres med et heltall. + +Hvert innslag i et array identifiseres med et nummer, fra og med `0`. + +Så i denne arrayet er `hei` identifisert ved nummeret `1`: + +```js +const hilsinger = ['hallo', 'hei', 'god morgen'] +``` + +Verdien kan nås slik som dette: + +```js +hilsinger[1] +``` + +Så på innsiden av en **for løkke** ville vi brukt `i` varibelen inni hakeparantesen istedenfor å bruke et tall. + +## Oppgaven: + +Lag en fil som heter `looping-through-arrays.js`. + +Definer en variabel `pets` som refererer til denne arrayet: + +```js +['cat', 'dog', 'rat'] +``` + +Lag en for løkke som endrer hver eneste string i det arrayet til flertall. + +Du vil måtte bruke et uttrykk som dette på inni for løkken: + +```js +pets[i] = pets[i] + 's' +``` + +Etter den for løkken, bruk `console.log()` for å skrive ut `pets` arrayet til skjermen. + +Se om programmet ditt er riktig ved å kjøre denne kommandoen: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_nl.md b/problems/looping-through-arrays/problem_nl.md new file mode 100755 index 00000000..e8ba4e51 --- /dev/null +++ b/problems/looping-through-arrays/problem_nl.md @@ -0,0 +1,45 @@ +In deze uitdaging gebruik je een **for loop** om een lijst met waarden in een array te lezen en aan te passen. + +Waarden in een array opvragen kan alleen door gebruik te maken van hele getallen (integers) + +Elke waarde in een array heeft een eigen index nummer, deze start altijd bij `0`. + +In deze array heeft `hi` het index nummer `1`: + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +Zo benader je die waarde in de array: + +```js +greetings[1] +``` + +In een **for loop** kun je de `i` variabele binnen de blokhaken gebruiken in plaats van een direct getal. + +## De uitdaging: + +Maak een nieuw bestand met de naam `looping-through-arrays.js`. + +Definieer in dit bestand een variabele met de naam `pets` die verwijst naar deze array: + +```js +['cat', 'dog', 'rat'] +``` + +Schrijf een for loop die elke string in de array verandert, zodat de woorden in het meervoud veranderen. + +Binnen de for loop gebruik je daarvoor dit statement: + +```js +pets[i] = pets[i] + 's' +``` + +Na de for loop gebruik je `console.log()` om de `pets` array naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_pt-br.md b/problems/looping-through-arrays/problem_pt-br.md new file mode 100644 index 00000000..df181b33 --- /dev/null +++ b/problems/looping-through-arrays/problem_pt-br.md @@ -0,0 +1,45 @@ +Para este desafio usaremos um **loop for** para acessar e manipular uma lista de valores em um array. + +Podemos acessar os valores de um array usando um contador. + +Cada item em um array é identificado por um número inteiro, começando do `0`. + +Então neste array a string `hi` é identificada pelo número `1`: + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +Podemos acessá-la dessa forma: + +```js +greetings[1] +``` + +Então dentro de um **loop for** usaríamos a variável `i` dentro dos colchetes ao invés de usar diretamente um inteiro. + +## Desafio: + +Crie um arquivo chamado `looping-through-arrays.js`. + +Neste arquivo, defina uma variável chamada `pets` que referencie este array: + +```js +['cat', 'dog', 'rat'] +``` + +Crie um loop for que altera cada string no array para o plural. + +Você usará uma instrução como esta dentro do loop: + +```js +pets[i] = pets[i] + 's' +``` + +Depois do loop, use o `console.log()` para imprimir o array `pets` no terminal. + +Verifique se o seu programa está correto usando o comando: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_ru.md b/problems/looping-through-arrays/problem_ru.md new file mode 100644 index 00000000..097bccc5 --- /dev/null +++ b/problems/looping-through-arrays/problem_ru.md @@ -0,0 +1,45 @@ +В этом задании мы будем использовать **цикл for** чтобы получить доступ и оперировать элементами в массиве. + +Осуществить доступ к значениям массива можно с использованием целочисленной переменной. + +Каждый элемент в массиве имеет соответствующий номер, начиная с `0`. + +Например в этом массиве элементу `hi` соответствует номер `1`: + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +Получить доступ к нему можно вот так: + +```js +greetings[1] +``` + +Следовательно, внутри **цикла for** в квадратных скобках мы укажем переменную `i`, вместо непосредственного использования чисел. + +## Условие задачи: + +Создайте файл `looping-through-arrays.js`. + +В этом файле объявите переменную `pets` которая ссылается на следующий массив: + +```js +['cat', 'dog', 'rat'] +``` + +Создайте цикл for, который меняет каждую строчку в массиве так, чтобы слова были в форме множественного числа. + +Используйте внутри цикла for следующее выражение: + +```js +pets[i] = pets[i] + 's' +``` + +После цикла воспользуйтесь `console.log()` и выведите в терминал массив `pets`. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_uk.md b/problems/looping-through-arrays/problem_uk.md new file mode 100644 index 00000000..91a20976 --- /dev/null +++ b/problems/looping-through-arrays/problem_uk.md @@ -0,0 +1,45 @@ +Для цього завдання ми використаємо **цикл for** для доступу та маніпуляції списку значень в масиві. + +Доступ до значень масиву можна здійснити з допомогою цілих чисел. + +Кожен елемент в масиві ідентифікується з допомогою числа, починаючи з `0`. + +Тому в цьому масиві `hi` ідентифікується числом `1`: + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +Доступ до нього можна отримати так: + +```js +greetings[1] +``` + +Всередині **циклу for** ми можемо використати змінну `i` всередині квадратних дужок, замість звичайного цілого числа. + +## Завдання: + +Створити файл `looping-through-arrays.js`. + +У цьому файлі задати змінну під назвою `pets`, що вказуватиме на масив: + +```js +['cat', 'dog', 'rat'] +``` + +Створити цикл for loop, що змінює кожен рядок масиву так, щоб слова в однині стали словами в множині (в англійській мові множина утворюється додаванням закінчення `-s` ). + +Ви можете використати такий вираз всередині циклу for: + +```js +pets[i] = pets[i] + 's' +``` + +Після циклу, використайте `console.log()`, щоб вивести масив `pets` до термінала. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_zh-cn.md b/problems/looping-through-arrays/problem_zh-cn.md index 059a4675..6589b229 100644 --- a/problems/looping-through-arrays/problem_zh-cn.md +++ b/problems/looping-through-arrays/problem_zh-cn.md @@ -1,7 +1,3 @@ ---- - -# 依次访问数组中的值 - 本次挑战中,我们将使用一个 **for 循环**来访问并操作数组中的值。 访问数组可以使用一个整数轻易办到。 @@ -11,13 +7,13 @@ 所以下面的数组中,数字 `1` 标识了 `hi`: ```js -var greetings = ['hello', 'hi', 'good morning']; +const greetings = ['hello', 'hi', 'good morning'] ``` 于是,`hi` 就可以像这样被访问: ```js -greetings[1]; +greetings[1] ``` 在 **for 循环**中,我们可以在方括号中使用变量 `i`,而不是直接地使用数字。 @@ -29,7 +25,7 @@ greetings[1]; 在文件中定义一个变量 `pets`,使它引用下面的数组: ```js -['cat', 'dog', 'rat']; +['cat', 'dog', 'rat'] ``` 创建一个 for 循环,把数组里的每一个字符串都变成复数。 @@ -37,13 +33,13 @@ greetings[1]; 在 for 循环里,你可以使用下面的语句: ```js -pets[i] = pets[i] + 's'; +pets[i] = pets[i] + 's' ``` 最后,使用 `console.log()` 打印 `pets` 数组到终端。 运行下面的命令检查你的程序是否正确: -`javascripting verify looping-through-arrays.js` - ---- +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/problem_zh-tw.md b/problems/looping-through-arrays/problem_zh-tw.md new file mode 100644 index 00000000..79aafe4f --- /dev/null +++ b/problems/looping-through-arrays/problem_zh-tw.md @@ -0,0 +1,45 @@ +本次挑戰中,我們將使用一個 **for 迴圈**來存取並操作陣列中的值。 + +存取陣列可以使用一個整數輕易辦到。 + +陣列中的每項元素都有一個唯一的索引值,是一個由 `0` 開始的整數。 + +所以下面的陣列中,數字 `1` 標識了 `hi`: + +```js +const greetings = ['hello', 'hi', 'good morning'] +``` + +於是,`hi` 就可以像這樣被存取: + +```js +greetings[1] +``` + +在 **for 迴圈**中,我們可以在中括號中使用變數 `i`,而不是直接地使用數字。 + +## 挑戰: + +建立一個名為 `looping-through-arrays.js` 的檔案。 + +在該檔案中定義一個名為 `pets` 的變數,使它引用下面的陣列: + +```js +['cat', 'dog', 'rat'] +``` + +建立一個 for 迴圈,把陣列裡的每一個字串都變成複數單字(尾端加上s)。 + +在 for 迴圈裡,你可以使用下面的語句: + +```js +pets[i] = pets[i] + 's' +``` + +最後,使用 `console.log()` 輸出 `pets` 陣列到終端機上。 + +執行下面的命令檢查你撰寫的程式是否正確: + +```bash +javascripting verify looping-through-arrays.js +``` diff --git a/problems/looping-through-arrays/solution_fr.md b/problems/looping-through-arrays/solution_fr.md new file mode 100644 index 00000000..034bb24b --- /dev/null +++ b/problems/looping-through-arrays/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# SUCCÈS ! PLEIN D'ANIMAUX ! + +Tous les éléments dans le tableau `pets` sont maintenant au pluriel ! + +Dans le prochain défi, nous allons découvrir les **objets**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/looping-through-arrays/solution_it.md b/problems/looping-through-arrays/solution_it.md new file mode 100644 index 00000000..2fd5520f --- /dev/null +++ b/problems/looping-through-arrays/solution_it.md @@ -0,0 +1,11 @@ +--- + +# SUCCESS! LOTS OF PETS! + +Now all the items in that `pets` array are plural! + +In the next challenge we will move from arrays to working with **objects**. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/looping-through-arrays/solution_nb-no.md b/problems/looping-through-arrays/solution_nb-no.md new file mode 100644 index 00000000..e4566851 --- /dev/null +++ b/problems/looping-through-arrays/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# FLOTT! MANGE KJÆLEDYR! + +Nå er alle innslagene i `pets` arrayet i flertall! + +I den neste oppgaven går vi fra arrayer til å jobbe med **objekter**. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/looping-through-arrays/solution_nl.md b/problems/looping-through-arrays/solution_nl.md new file mode 100644 index 00000000..908cd0fd --- /dev/null +++ b/problems/looping-through-arrays/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# SUCCES! DIEREN IN MEERVOUD! + +Alle items in de `pets` array zijn nu in meervoud! + +In de volgende uitdaging gaan we van arrays naar het werken met objecten. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/looping-through-arrays/solution_pt-br.md b/problems/looping-through-arrays/solution_pt-br.md new file mode 100644 index 00000000..2d068dad --- /dev/null +++ b/problems/looping-through-arrays/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# SUCESSO! UM MONTE DE BICHINHOS! + +Agora todos os itens no array `pets` estão no plural! + +No próximo desafio vamos começar á trabalhar com **objects**. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/looping-through-arrays/solution_ru.md b/problems/looping-through-arrays/solution_ru.md new file mode 100644 index 00000000..84572a6b --- /dev/null +++ b/problems/looping-through-arrays/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ПОБЕДА! КУЧА ДОМАШНИХ ЖИВОТНЫХ! + +Теперь все элементы массива `pets` находятся в форме множественного числа. + +В следующем упражнении мы перейдем от массивов к **объектам**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- \ No newline at end of file diff --git a/problems/looping-through-arrays/solution_uk.md b/problems/looping-through-arrays/solution_uk.md new file mode 100644 index 00000000..fc78d514 --- /dev/null +++ b/problems/looping-through-arrays/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# УСПІХ! БАГАТО ТВАРИНОК! + +Тепер всі елементи в масиві `pets` у множині! + +В наступному завданні ми перейдемо від масивів до роботи з **об’єктами**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/looping-through-arrays/solution_zh-tw.md b/problems/looping-through-arrays/solution_zh-tw.md new file mode 100644 index 00000000..e438c99e --- /dev/null +++ b/problems/looping-through-arrays/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 成功!現在你有了很多貓貓狗狗! + +現在 `pets` 陣列中的所有元素都變成了複數。 + +下一個挑戰裡,我們將學習 **objects**,也就是 **物件**。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/number-to-string/index.js b/problems/number-to-string/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/number-to-string/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/number-to-string/problem.md b/problems/number-to-string/problem.md index 1c648f8d..376e163b 100644 --- a/problems/number-to-string/problem.md +++ b/problems/number-to-string/problem.md @@ -1,14 +1,10 @@ ---- - -# NUMBER TO STRING - Sometimes you will need to turn a number into a string. In those instances you will use the `.toString()` method. Here's an example: ```js -var n = 256; -n = n.toString(); +let n = 256 +n = n.toString() ``` ## The challenge: @@ -23,6 +19,6 @@ Use `console.log()` to print the results of the `.toString()` method to the term Check to see if your program is correct by running this command: -`javascripting verify number-to-string.js` - ---- +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_es.md b/problems/number-to-string/problem_es.md index c1d3c4ce..4761c12b 100644 --- a/problems/number-to-string/problem_es.md +++ b/problems/number-to-string/problem_es.md @@ -1,14 +1,10 @@ ---- - -# NÚMERO A STRING - A veces necesitarás convertir un número a una string. En esos casos, usarás el método `.toString()`. A continuación un ejemplo: ```js -var n = 256; -n.toString(); +const n = 256 +n.toString() ``` ## El ejercicio @@ -23,6 +19,6 @@ Utiliza `console.log()` para imprimir los resultados de `.toString()` a la termi Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify number-to-string.js` - ---- +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_fr.md b/problems/number-to-string/problem_fr.md new file mode 100644 index 00000000..f7476994 --- /dev/null +++ b/problems/number-to-string/problem_fr.md @@ -0,0 +1,24 @@ +Vous devez parfois transformer un nombre en chaîne de caractère. + +Dans ces cas là, vous utiliserez la méthode `.toString()`. Voici un exemple : + +```js +let n = 256 +n = n.toString() +``` + +## Le défi : + +Créez un fichier nommé `nombre-en-chaine.js`. + +Dans ce fichier, définissez une variable nommée `n` qui contient le nombre `128`. + +Appelez la méthode `.toString()` sur la variable `n`. + +Utilisez `console.log()` pour afficher le résultat de la méthode `.toString()` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify nombre-en-chaine.js +``` diff --git a/problems/number-to-string/problem_it.md b/problems/number-to-string/problem_it.md new file mode 100644 index 00000000..1850b613 --- /dev/null +++ b/problems/number-to-string/problem_it.md @@ -0,0 +1,24 @@ +A volte è necessario trasformare un numero in una stringa. + +In quei casi, userai il metodo `.toString()`. Ecco un esempio: + +```js +let n = 256 +n = n.toString() +``` + +## La sfida: + +Crea un file dal nome `number-to-string.js`. + +In questo file definisci una variabile chiamata `n` che referenzia il numero `128`; + +Invoca il metodo `.toString()` sulla variabile `n`. + +Usa `console.log()` per stampare i risultati del metodo `.toString()` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_ja.md b/problems/number-to-string/problem_ja.md index 80d8ae2c..e380e72f 100644 --- a/problems/number-to-string/problem_ja.md +++ b/problems/number-to-string/problem_ja.md @@ -1,14 +1,10 @@ ---- - -# 数値を文字列に - 数値を文字列に変換したいことがあります。 そういう時は `toString()` メソッドを使います。たとえば... ```js -var n = 256; -n = n.toString(); +let n = 256 +n = n.toString() ``` ## やってみよう @@ -23,6 +19,6 @@ n = n.toString(); 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify number-to-string.js` - ---- +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_ko.md b/problems/number-to-string/problem_ko.md index 17eaeac3..854a19e5 100644 --- a/problems/number-to-string/problem_ko.md +++ b/problems/number-to-string/problem_ko.md @@ -1,14 +1,10 @@ ---- - -# 숫자에서 문자열으로 - 가끔 숫자를 문자열로 변경해야 할 때가 있습니다. 그런 경우에 `.toString()` 메소드를 사용하면 됩니다. 예제를 보세요. ```js -var n = 256; -n = n.toString(); +let n = 256 +n = n.toString() ``` ## 도전 과제 @@ -23,6 +19,6 @@ n = n.toString(); 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify number-to-string.js` - ---- +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_nb-no.md b/problems/number-to-string/problem_nb-no.md new file mode 100644 index 00000000..73c1d07e --- /dev/null +++ b/problems/number-to-string/problem_nb-no.md @@ -0,0 +1,24 @@ +Noen ganger må du gjøre om et nummer til en string. + +I de tilfelle må du bruke `.toString()` metoden. Eksempel: + +```js +let nummer = 256 +nummer = nummer.toString() +``` + +## Oppgaven: + +Lag en fil som heter `number-to-string.js`. + +Definer en variabel med navnet `n` som referer nummeret `128` i den filen. + +Kall `.toString()` metoden på den `n` variabelen. + +Bruk `console.log()` for å skrive ut resultatet av `.toString()` metoden til skjermen. + +Se om programmet ditt er riktig ved å kjøre denne kommandoen: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_nl.md b/problems/number-to-string/problem_nl.md new file mode 100755 index 00000000..a7c96426 --- /dev/null +++ b/problems/number-to-string/problem_nl.md @@ -0,0 +1,24 @@ +Soms moet je een number omzetten in een string. + +In dat geval gebruik je de `.toString()` method. Hier is een voorbeeld: + +```js +let n = 256 +n = n.toString() +``` + +## De uitdaging + +Maak een bestand met de naam `number-to-string.js`. + +Definieer in het bestand een variabele met de naam `n` die verwijst naar het getal `128`; + +Roep de `.toString()` method aan op de variabele `n`. + +Gebruik `console.log()` om de uitvoer van de `.toString()` method naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_pt-br.md b/problems/number-to-string/problem_pt-br.md new file mode 100644 index 00000000..b9fba7d4 --- /dev/null +++ b/problems/number-to-string/problem_pt-br.md @@ -0,0 +1,24 @@ +Ás vezes você precisará converter um número para uma string. + +Nestas situações você usará o método `.toString()`. Veja um exemplo de como usá-lo: + +```js +let n = 256 +n = n.toString() +``` + +## Desafio: + +Crie um arquivo chamado `number-to-string.js`. + +Neste arquivo defina uma variável chamada `n` que referencia o número `128`; + +Chame o método `.toString()` na variável `n`. + +Use o `console.log()`para imprimir o resultado do método `.toString()` no terminal. + +Verifique se o seu programa está correto executando o comando: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_ru.md b/problems/number-to-string/problem_ru.md new file mode 100644 index 00000000..b7bdea2e --- /dev/null +++ b/problems/number-to-string/problem_ru.md @@ -0,0 +1,24 @@ +Иногда необходимо представить число в виде строки. + +В этом случае используйте метод `.toString()`. Например: + +```js +let n = 256 +n = n.toString() +``` + +## Условие задачи: + +Создайте файл `number-to-string.js`. + +В этом файле объявите переменную `n`, которая ссылается на число `128`. + +Вызовите у переменной `n` метод `.toString()`. + +Используйте `console.log()` и выведите в терминал результат работы метода `.toString()`. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_uk.md b/problems/number-to-string/problem_uk.md new file mode 100644 index 00000000..7dce3460 --- /dev/null +++ b/problems/number-to-string/problem_uk.md @@ -0,0 +1,24 @@ +Часом нам потрібно перетворити числа в рядки. + +В таких випадках ви можете використати метод `.toString()`. Ось приклад: + +```js +let n = 256 +n = n.toString() +``` + +## Завдання: + +Створіть файл `number-to-string.js`. + +У цьому файлі оголосіть змінну під назвою `n`, що буде містити число `128`; + +Викличіть метод `.toString()` змінної `n`. + +Використайте `console.log()` для виведення результату роботи методу `.toString()` до терміналу. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_zh-cn.md b/problems/number-to-string/problem_zh-cn.md index 8768c546..4b98b411 100644 --- a/problems/number-to-string/problem_zh-cn.md +++ b/problems/number-to-string/problem_zh-cn.md @@ -1,14 +1,10 @@ ---- - -# 数字转字符串 - 有时候我们需要把一个数字转换成字符串。 这时,你可以使用 `.toString()` 方法。例如: ```js -var n = 256; -n = n.toString(); +let n = 256 +n = n.toString() ``` ## 挑战: @@ -23,6 +19,6 @@ n = n.toString(); 运行下面的命令来检查你的程序是否正确: -`javascripting verify number-to-string.js` - ---- +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/problem_zh-tw.md b/problems/number-to-string/problem_zh-tw.md new file mode 100644 index 00000000..4cdf52e4 --- /dev/null +++ b/problems/number-to-string/problem_zh-tw.md @@ -0,0 +1,24 @@ +有時候我們需要把一個數字轉換成字串。 + +這時,你可以使用 `.toString()` 方法。例如: + +```js +let n = 256 +n = n.toString() +``` + +## 挑戰: + +建立一個名為 `number-to-string.js` 的檔案。 + +在該檔案中定義一個名為 `n` 的變數,並賦值 `128`; + +在變數 `n` 上呼叫 `.toString()` 方法。 + +使用 `console.log()` 將 `.toString()` 方法的結果輸出到終端機上。 + +執行下面的命令來檢查你撰寫的程式是否正確: + +```bash +javascripting verify number-to-string.js +``` diff --git a/problems/number-to-string/solution_fr.md b/problems/number-to-string/solution_fr.md new file mode 100644 index 00000000..36140ec4 --- /dev/null +++ b/problems/number-to-string/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# CE NOMBRE EST MAINTENANT UNE CHAÎNE DE CARACTÈRES ! + +Excellent. Vous avez réussi à convertir un nombre en chaîne de caractères. + +Dans le prochain défi, nous nous intéresserons aux **instructions if**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/number-to-string/solution_it.md b/problems/number-to-string/solution_it.md new file mode 100644 index 00000000..700a4d85 --- /dev/null +++ b/problems/number-to-string/solution_it.md @@ -0,0 +1,11 @@ +--- + +# THAT NUMBER IS NOW A STRING! + +Excellent. Good work converting that number into a string. + +In the next challenge we will take a look at **if statements**. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/number-to-string/solution_nb-no.md b/problems/number-to-string/solution_nb-no.md new file mode 100644 index 00000000..bd78be15 --- /dev/null +++ b/problems/number-to-string/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# NUMMERET ER NÅ EN STRING! + +Fantastisk. Godt jobba med å konvertere et nummer til en string. + +I den neste oppgaven skal vi ta en titt på **if-setninger**. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/number-to-string/solution_nl.md b/problems/number-to-string/solution_nl.md new file mode 100644 index 00000000..ea6959ee --- /dev/null +++ b/problems/number-to-string/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# HET NUMMER IS NU EEN STRING! + +Geweldig. Je hebt het nummer veranderd in een string! + +In volgende uitdaging gaan we kijken naar **if statements**. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/number-to-string/solution_pt-br.md b/problems/number-to-string/solution_pt-br.md new file mode 100644 index 00000000..c7605218 --- /dev/null +++ b/problems/number-to-string/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# ESTE NÚMERO AGORA É UMA STRING! + +Excelente! Você fez um bom trabalho convertendo o número em uma string. + +No próximo desafio vamos ver como fazer condições usando **if**. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/number-to-string/solution_ru.md b/problems/number-to-string/solution_ru.md new file mode 100644 index 00000000..d1d27cc2 --- /dev/null +++ b/problems/number-to-string/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ТЕПЕРЬ ЭТО ЧИСЛО -- СТРОКА! + +Превосходно! Отличная работа по представлению числа в виде строки. + +В следующем упражнении мы посмотрим на **оператор if**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/number-to-string/solution_uk.md b/problems/number-to-string/solution_uk.md new file mode 100644 index 00000000..d98de65b --- /dev/null +++ b/problems/number-to-string/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ЦЕ ЧИСЛО СТАЛО РЯДКОМ! + +Відмінно. Ви добре впорались з перетворенням числа в рядок. + +В наступному завданні ми подивимось на **оператор if**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/number-to-string/solution_zh-tw.md b/problems/number-to-string/solution_zh-tw.md new file mode 100644 index 00000000..ea659697 --- /dev/null +++ b/problems/number-to-string/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 那個數字已經變成了字串! + +完美。你已經學會了如何將一個數字轉換為字串。 + +接下來的挑戰裡我們將學習的是 **if 條件式**。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/numbers/index.js b/problems/numbers/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/numbers/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/numbers/problem.md b/problems/numbers/problem.md index d0e38ee4..9b9655ce 100644 --- a/problems/numbers/problem.md +++ b/problems/numbers/problem.md @@ -1,9 +1,6 @@ ---- - -# NUMBERS - Numbers can be integers, like `2`, `14`, or `4353`, or they can be decimals, also known as floats, like `3.14`, `1.5`, or `100.7893423`. +Unlike Strings, Numbers do not need to have quotes. ## The challenge: @@ -16,5 +13,3 @@ Use `console.log()` to print that number to the terminal. Check to see if your program is correct by running this command: `javascripting verify numbers.js` - ---- diff --git a/problems/numbers/problem_es.md b/problems/numbers/problem_es.md index 0fc97d97..c5733613 100644 --- a/problems/numbers/problem_es.md +++ b/problems/numbers/problem_es.md @@ -1,8 +1,4 @@ ---- - -# NÚMEROS - -Los números pueden ser enterios, cómo `3`, `5` o `3337`, o pueden ser decimales, +Los números pueden ser enteros, cómo `3`, `5` o `3337`, o pueden ser decimales, cómo `3.14`, `1.5` o `100.7893423`. ## El ejercicio: @@ -16,5 +12,3 @@ Utiliza `console.log()` para imprimir ese número a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: `javascripting verify numbers.js` - ---- diff --git a/problems/numbers/problem_fr.md b/problems/numbers/problem_fr.md new file mode 100644 index 00000000..17b95e05 --- /dev/null +++ b/problems/numbers/problem_fr.md @@ -0,0 +1,14 @@ +Les nombres peuvent être des entiers, comme `2`, `14`, ou `4353`, ou décimaux, aussi appelés `floats`, comme `3.14`, `1.5`, ou `100.7893423`. +Contrairement aux chaînes de caractères, les nombres ne sont pas entourés par des guillemets. + +## Le défi : + +Créez un fichier nommé `nombres.js`. + +Dans ce fichier, définissez une variable nommée `example` qui contient l'entier `123456789`. + +Utilisez `console.log()` pour afficher ce nombre dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +`javascripting verify nombres.js` diff --git a/problems/numbers/problem_it.md b/problems/numbers/problem_it.md new file mode 100644 index 00000000..48e7b965 --- /dev/null +++ b/problems/numbers/problem_it.md @@ -0,0 +1,15 @@ +I numeri possono essere interi, come `2`, `14` o `4353`, o possono essere decimali, +conosciuti anche come `float`, com `3.14`, `1.5` o `100.7893423`. +Diversamente dalle stringhe, i numeri non hanno bisogno di apici. + +## La sfida: + +Crea un file dal nome `numbers.js`. + +In questo file definisci una variabile chiamata `example` che referenzia l'intero `123456789`. + +Usa `console.log()` per stampare il numero sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +`javascripting verify numbers.js` diff --git a/problems/numbers/problem_ja.md b/problems/numbers/problem_ja.md index f1263c6e..2d842426 100644 --- a/problems/numbers/problem_ja.md +++ b/problems/numbers/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 数値 - JavaScriptの数値は `2` 、`14` 、`4353` のような整数と `3.14` 、 `1.5` 、 `100.7893423` のような小数のどちらともを表すことができます。 @@ -17,5 +13,3 @@ JavaScriptの数値は `2` 、`14` 、`4353` のような整数と 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 `javascripting verify numbers.js` - ---- diff --git a/problems/numbers/problem_ko.md b/problems/numbers/problem_ko.md index 9e7c067a..7785f06f 100644 --- a/problems/numbers/problem_ko.md +++ b/problems/numbers/problem_ko.md @@ -1,8 +1,5 @@ ---- - -# 숫자 - 숫자는 `2`, `14`, `4353` 같은 정수이거나 십진수이거나 `3.14`, `1.5`, `100.7893423` 같은 실수일 수 있습니다. +문자열과 다르게 숫자는 따옴표로 감쌀 필요가 없습니다. ## 도전 과제 @@ -15,5 +12,3 @@ 이 명령어를 실행해 프로그램이 올바른지 확인하세요. `javascripting verify numbers.js` - ---- diff --git a/problems/numbers/problem_nb-no.md b/problems/numbers/problem_nb-no.md new file mode 100644 index 00000000..7a6070fb --- /dev/null +++ b/problems/numbers/problem_nb-no.md @@ -0,0 +1,14 @@ +Nummer kan være heltall, som `2`, `14` eller `4353`, eller de kan være desimaltall +også kjent som flyttall slik som `3.14`, `1.5` eller `100.7893423`. + +## Oppgaven: + +Lag en fil som heter `numbers.js`. + +Definer en variabel `example` som referer heltallet `123456789` i den filen. + +Brukt `console.log()` for å skrive nummeret til skjermen. + +Se om programmet ditt er riktig ved å kjøre denne kommandoen: + +`javascripting verify numbers.js` diff --git a/problems/numbers/problem_nl.md b/problems/numbers/problem_nl.md new file mode 100755 index 00000000..530b7556 --- /dev/null +++ b/problems/numbers/problem_nl.md @@ -0,0 +1,16 @@ +Numbers kunnen hele getallen zijn, zoals `2`, `14`, or `4353`, of getallen met cijfers achter de komma, ook wel +floats genoemd, zoals `3.14`, `1.5`, of `100.7893423`. + +Numbers declareer je altijd zonder aanhalingstekens. + +## De uitdaging + +Maak een bestand met de naam `numbers.js`. + +Maak in dit bestand een variabele met de naam `example` die verwijst naar het hele getal `123456789`. + +Gebruik `console.log()` om dit getal naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +`javascripting verify numbers.js` diff --git a/problems/numbers/problem_pt-br.md b/problems/numbers/problem_pt-br.md new file mode 100644 index 00000000..8db5421e --- /dev/null +++ b/problems/numbers/problem_pt-br.md @@ -0,0 +1,14 @@ +O números podem ser inteiros como `2`, `14`, ou `4353`, ou podem ser decimais +como `3.14`, `1.5`, ou `100.7893423`. + +## Desafio: + +Crie um arquivo chamado `numbers.js`. + +No arquivo defina uma variável chamada `example` que referencia o valor `123456789`. + +Use o `console.log()` para imprimir o número no terminal. + +Verifique se o seu programa está correto executando o seguinte comando: + +`javascripting verify numbers.js` diff --git a/problems/numbers/problem_ru.md b/problems/numbers/problem_ru.md new file mode 100644 index 00000000..f3f18a9c --- /dev/null +++ b/problems/numbers/problem_ru.md @@ -0,0 +1,16 @@ +Числа могут быть как целые, например `2`, `14`, так и десятичные, также известные как числа с плавающей точкой, например `3.14`, `1.5`, или `100.7893423`. +В отличие от строк, числам не нужны кавычки. + +## Условие задачи: + +Создайте файл `numbers.js`. + +В этом файле объявите переменную `example`, которая ссылается на целое число `123456789`. + +Используйте `console.log()` чтобы вывести это число в терминал. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify numbers.js +``` \ No newline at end of file diff --git a/problems/numbers/problem_uk.md b/problems/numbers/problem_uk.md new file mode 100644 index 00000000..b64f4707 --- /dev/null +++ b/problems/numbers/problem_uk.md @@ -0,0 +1,14 @@ +Числа (Numbers) можуть бути цілими, як от `2`, `14`, або `4353`. Також вони можуть бути дійсними, також відомі як «числа з плаваючою крапкою», як от `3.14`, `1.5`, або `100.7893423`. +На відміну від рядків (Strings), числа (Numbers) не потрібно огортати лапками. + +## Завдання: + +Створити файл `numbers.js`. + +У цьому файлі задати змінну під назвою `example`, що буде містити ціле число `123456789`. + +Використайте `console.log()`, щоб вивести це число до терміналу. + +Перевірте вашу відповідь запустивши команду: + +`javascripting verify numbers.js` diff --git a/problems/numbers/problem_zh-cn.md b/problems/numbers/problem_zh-cn.md index d3d28f71..d147557f 100644 --- a/problems/numbers/problem_zh-cn.md +++ b/problems/numbers/problem_zh-cn.md @@ -1,8 +1,5 @@ ---- - -# 数字 - 数字既可以是整数,像 `2`,`14`,或者 `4353`,也可以是小数,通常也被称为浮点数,比如 `3.14`,`1.5`,和 `100.7893423`。 +跟字符串不一样,数字不需要使用单引号或双引号括起来。 ## 挑战: @@ -10,10 +7,8 @@ 在文件中定义一个名为 `example` 的变量并让它引用整数 `123456789`。 -使用 `console.log()` 打印这个数到终端。 +使用 `console.log()` 输出打印这个数到终端。 运行下面的命令检查你的程序是否正确: `javascripting verify numbers.js` - ---- diff --git a/problems/numbers/problem_zh-tw.md b/problems/numbers/problem_zh-tw.md new file mode 100644 index 00000000..5db7dd81 --- /dev/null +++ b/problems/numbers/problem_zh-tw.md @@ -0,0 +1,13 @@ +數字既可以是整數,像 `2`,`14`,或者 `4353`,也可以是小數,通常也被稱為浮點數,比如 `3.14`,`1.5`,和 `100.7893423`。 + +## 挑戰: + +建立一個名為 `numbers.js` 的檔案。 + +在該檔案中定義一個名為 `example` 的變數並賦予它整數 `123456789`。 + +使用 `console.log()` 印出這個數字到終端機上。 + +執行下面的命令檢查你的程序是否正確: + +`javascripting verify numbers.js` diff --git a/problems/numbers/solution_fr.md b/problems/numbers/solution_fr.md new file mode 100644 index 00000000..c4228d5c --- /dev/null +++ b/problems/numbers/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# YEAH ! DES NOMBRES ! + +Génial ! Vous avez défini avec succès une variable contenant le nombre `123456789`. + +Dans le prochain défi, nous nous intéresserons à la manipulation de nombres. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/numbers/solution_it.md b/problems/numbers/solution_it.md new file mode 100644 index 00000000..12432af5 --- /dev/null +++ b/problems/numbers/solution_it.md @@ -0,0 +1,11 @@ +--- + +# SÌ! NUMERI! + +Perfetto, hai definito con successo una variabile con il valore numerico `123456789`. + +Nella prossima sfida vedremo come manipolare i numeri. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/numbers/solution_nb-no.md b/problems/numbers/solution_nb-no.md new file mode 100644 index 00000000..32d3d8ed --- /dev/null +++ b/problems/numbers/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# SE DER JA! NUMMER! + +Kult, du fikk til å definere en variabel med nummeret `123456789`. + +I den neste oppgaven skal vi endre nummer. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/numbers/solution_nl.md b/problems/numbers/solution_nl.md new file mode 100644 index 00000000..0b6c818d --- /dev/null +++ b/problems/numbers/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# YEAH! NUMBERS! + +Cool, je hebt met succes een number variabele gedefinieerd met het getal `123456789`. + +In volgende uitdaging gaan we nummers aanpassen. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/numbers/solution_pt-br.md b/problems/numbers/solution_pt-br.md new file mode 100644 index 00000000..c53ee68b --- /dev/null +++ b/problems/numbers/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# SIM! NÚMEROS! + +Legal, você conseguiu definir uma variável com o valor `123456789`. + +No próximo desafio vamos ver como manipular os números. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/numbers/solution_ru.md b/problems/numbers/solution_ru.md new file mode 100644 index 00000000..a7d1124c --- /dev/null +++ b/problems/numbers/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ДА! ЧИСЛА! + +Клево, вы успешно объявили переменную с числом `123456789`. + +В следующем упражнении мы посмотрим как обращаться с числами. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- \ No newline at end of file diff --git a/problems/numbers/solution_uk.md b/problems/numbers/solution_uk.md new file mode 100644 index 00000000..a884fb6f --- /dev/null +++ b/problems/numbers/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ТАААК! ЧИСЛА! + +Круто, ви успішно оголосили змінну з числом `123456789`. + +В наступному завданні ми подивимось як оперувати числами.s. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/numbers/solution_zh-tw.md b/problems/numbers/solution_zh-tw.md new file mode 100644 index 00000000..d4cb5c45 --- /dev/null +++ b/problems/numbers/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# YEAH!奇妙的數字! + +你成功地定義了一個變數並給它賦了值 `123456789`。 + +下一個挑戰中我們將學習如何對數字進行操作。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/object-keys/index.js b/problems/object-keys/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/object-keys/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/object-keys/problem.md b/problems/object-keys/problem.md index 09d67ae1..1b07c63f 100644 --- a/problems/object-keys/problem.md +++ b/problems/object-keys/problem.md @@ -1,5 +1,44 @@ ---- +JavaScript provides a native way of listing all the available keys of an object. This can be helpful for looping through all the properties of an object and manipulating their values accordingly. -# +Here's an example of listing all object keys using the **Object.keys()** +prototype method. ---- +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +The above code will print an array of strings, where each string is a key in the car object. `['make', 'model', 'year']` + +## The challenge: + +Create a file named `object-keys.js`. + +In that file, define a variable named `car` like this: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Then define another variable named `keys` like this: +```js +const keys = Object.keys(car) +``` + +Use `console.log()` to print the `keys` variable to the terminal. + +Check to see if your program is correct by running this command: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_es.md b/problems/object-keys/problem_es.md index 09d67ae1..418cfbca 100644 --- a/problems/object-keys/problem_es.md +++ b/problems/object-keys/problem_es.md @@ -1,5 +1,48 @@ ---- +JavaScript nos da una manera nativa de listar todas las _llaves_ (_keys_) de +un objeto. Esto puede ser muy útil para iterar sobre las propiedades de un +objeto y manipular sus valores. -# +Veámos un ejemplo de cómo podríamos listar todas las propiedades de un objeto +usando el método **Object.keys()**: ---- +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +El código de arriba imprime un arreglo de _strings_, donde cada _string_ es una +_llave_ (_key_) en el objeto `car` (`['make', 'model', 'year']`). + +## El ejercicio: + +Crea un archivo llamado `object-keys.js`. + +En ese archivo, define una variable llamada `car`: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Después define otra variable llamada `keys`: + +```js +const keys = Object.keys(car) +``` + +Usa `console.log()` para imprimir la variable `keys` en la consola. + +Comprueba si tu programa es correcto ejecutando el siguiente comando: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_fr.md b/problems/object-keys/problem_fr.md new file mode 100644 index 00000000..b0ce8563 --- /dev/null +++ b/problems/object-keys/problem_fr.md @@ -0,0 +1,43 @@ +JavaScript fournit un moyen natif de lister toutes les clés disponibles d'un objet. Ceci peut être utile pour parcourir en boucle toutes les propriétés d'un objet et manipuler leurs valeurs en conséquence. + +Voici un exemple de liste de toutes les clés d'objets utilisant la méthode prototype **Object.keys()**. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +Le code ci-dessus imprimera un tableau de _strings_, où chaque _string_ est une _clé_ (_key_) dans l'objet `car`. `['make', 'model', 'year']` + +## The challenge: + +Créez un fichier nommé `object-keys.js`. + +Dans ce fichier, définissez une variable nommée `car` comme ceci: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Définissez ensuite une autre variable nommée `keys` comme ceci: +```js +const keys = Object.keys(car) +``` + +Utilisez `console.log()` pour imprimer la variable `keys` sur le terminal. + +Vérifiez si votre programme est correct en exécutant cette commande: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_it.md b/problems/object-keys/problem_it.md new file mode 100644 index 00000000..1d9bdb9f --- /dev/null +++ b/problems/object-keys/problem_it.md @@ -0,0 +1,43 @@ +JavaScript fornisce un modo nativo per elencare tutte le chiavi disponibili di un oggetto. Questo può essere utile per scorrere in sequenza tutte le proprietà di un oggetto e manipolarne i valori di conseguenza. + +Ecco un esempio di elencazione di tutte le chiavi dell'oggetto usando il metodo prototipo **Object.keys()**. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +Il codice sopra stamperà una matrice di stringhe, in cui ogni stringa è una chiave nell'oggetto car. `['make', 'model', 'year']` + +## The challenge: + +Crea un file chiamato `object-keys.js`. + +In quel file, definire una variabile denominata `car` come questa: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Quindi definire un'altra variabile denominata `keys` come questa: +```js +const keys = Object.keys(car) +``` + +Usa `console.log ()` per stampare la variabile `keys` sul terminale + +Controlla se il tuo programma è corretto eseguendo questo comando: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_ja.md b/problems/object-keys/problem_ja.md index 09d67ae1..258fd452 100644 --- a/problems/object-keys/problem_ja.md +++ b/problems/object-keys/problem_ja.md @@ -1,5 +1,44 @@ ---- +JavaScriptはオブジェクトの利用可能なキーを全て列挙する方法を提供しています.これは,ループ処理によってオブジェクトに応じた値の操作に役立ちます. -# +これは **Object.keys()** を使って全てのオブジェクトのキーを列挙する例です. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +上記のコードでは,文字列の配列が表示されます.各文字列はオブジェクトのキーです. `['make', 'model', 'year']` + +## やってみよう + +`object-keys.js`ファイルを作りましょう. + +ファイルの中で,変数`car`を定義します. + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +そして,別の変数`keys`を定義します. +```js +const keys = Object.keys(car) +``` + +`console.log()`を使って,変数`keys` をターミナルに表示しましょう. + +次のコマンドを実行し,あなたのプログラムが正しく動くか確認しましょう. + +```bash +javascripting verify object-keys.js +``` ---- diff --git a/problems/object-keys/problem_ko.md b/problems/object-keys/problem_ko.md index 09d67ae1..1b07c63f 100644 --- a/problems/object-keys/problem_ko.md +++ b/problems/object-keys/problem_ko.md @@ -1,5 +1,44 @@ ---- +JavaScript provides a native way of listing all the available keys of an object. This can be helpful for looping through all the properties of an object and manipulating their values accordingly. -# +Here's an example of listing all object keys using the **Object.keys()** +prototype method. ---- +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +The above code will print an array of strings, where each string is a key in the car object. `['make', 'model', 'year']` + +## The challenge: + +Create a file named `object-keys.js`. + +In that file, define a variable named `car` like this: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Then define another variable named `keys` like this: +```js +const keys = Object.keys(car) +``` + +Use `console.log()` to print the `keys` variable to the terminal. + +Check to see if your program is correct by running this command: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_nb-no.md b/problems/object-keys/problem_nb-no.md new file mode 100644 index 00000000..1b07c63f --- /dev/null +++ b/problems/object-keys/problem_nb-no.md @@ -0,0 +1,44 @@ +JavaScript provides a native way of listing all the available keys of an object. This can be helpful for looping through all the properties of an object and manipulating their values accordingly. + +Here's an example of listing all object keys using the **Object.keys()** +prototype method. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +The above code will print an array of strings, where each string is a key in the car object. `['make', 'model', 'year']` + +## The challenge: + +Create a file named `object-keys.js`. + +In that file, define a variable named `car` like this: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Then define another variable named `keys` like this: +```js +const keys = Object.keys(car) +``` + +Use `console.log()` to print the `keys` variable to the terminal. + +Check to see if your program is correct by running this command: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_nl.md b/problems/object-keys/problem_nl.md new file mode 100755 index 00000000..f1a03f96 --- /dev/null +++ b/problems/object-keys/problem_nl.md @@ -0,0 +1,43 @@ +JavaScript heeft een ingebouwde manier om alle beschikbare keys van een object weer te geven. Dit kan handig zijn als je alle eigenschappen van een object wilt doorlopen en de waarden wilt manipuleren. + +Hier is een voorbeeld dat alle object keys ophaalt door gebruik te maken van de **Object.keys()** method. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +De code hierboven print een array met strings, elke string is een key in het car object. `['make', 'model', 'year']` + +## De uitdaging: + +Maak een nieuw bestand met de naam `object-keys.js`. + +Definieer in dit bestand een nieuwe variabele `car` zoals hieronder: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Definieer nu een andere variabele met de naam `keys` zoals hieronder: +```js +const keys = Object.keys(car) +``` + +Gebruik `console.log()` om de `keys` variabele naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_pt-br.md b/problems/object-keys/problem_pt-br.md new file mode 100644 index 00000000..b1362a4c --- /dev/null +++ b/problems/object-keys/problem_pt-br.md @@ -0,0 +1,43 @@ +JavaScript nos fornece uma maneira nativa de listar todas as _chaves_ (_keys_) disponiveis de um objeto. Isso pode ser util para iterar em todas as propriedades de um objeto e manipular seus valores. + +Vejamos um exemplo de como podemos listar todas as chaves de um objeto utilizando o método Object.keys(): + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +O código acima imprime um array de _strings_, onde cada _string_ é uma _chave_ (_key_) do objeto `car`. `['make', 'model', 'year']` + +## Desafio: + +Crie um arquivo chamado `object-keys.js`. + +Dentro desse arquivo, defina uma variavel chamada `car`: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Então defina outra variavel chamada `keys`: +```js +const keys = Object.keys(car) +``` + +Utilize `console.log()` para imprimir a variavel `keys` no terminal. + +Verifique se seu programa está correto executando este comando: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_ru.md b/problems/object-keys/problem_ru.md new file mode 100644 index 00000000..f7dbce67 --- /dev/null +++ b/problems/object-keys/problem_ru.md @@ -0,0 +1,43 @@ +JavaScript предоставляет собственный способ перечисления всех доступных ключей объекта. Это может быть полезно для перебора всех свойств объекта и соответственно манипулирования их значениями. + +Вот пример перечисления всех ключей объекта с использованием метода-прототипа **Object.keys()**. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +Код выше выведет массив строк, где каждая строка - ключ в объекте "авто". `['make', 'model', 'year']` + +## The challenge: + +Создайте файл с именем `object-keys.js`. + +В этом файле объявите переменную с именем `car` вот так: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Затем объявите другую переменную с именем `keys` вот так: +```js +const keys = Object.keys(car) +``` + +Используйте `console.log()` для вывода переменной `keys` в терминал. + +Проверьте, правильна ли ваша программа, выполнив эту команду: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_uk.md b/problems/object-keys/problem_uk.md new file mode 100644 index 00000000..a17c56cb --- /dev/null +++ b/problems/object-keys/problem_uk.md @@ -0,0 +1,43 @@ +JavaScript забезпечує власний спосіб перерахування всіх доступних ключів об'єкта. Це може бути корисно для перегляду всіх властивостей об'єкта та відповідного маніпулювання їх значеннями. + +Ось приклад перерахування всіх ключів об'єкта за допомогою методу-прототипу **Object.keys()**. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +Вищевказаний код надрукує масив рядків, де кожен рядок є ключем в об'єкті "авто". `['make', 'model', 'year']` + +## The challenge: + +Створіть файл з назвою `object-keys.js`. + +У цьому файлі задайте змінну з назвою `car` ось так: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Потім задайте змінну з назвою `keys` ось так: +```js +const keys = Object.keys(car) +``` + +Використовуйте `console.log()` для друку змінної `keys` до терміналу. + +Перевірте, чи правильно працює ваша програма, виконавши цю команду: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_zh-cn.md b/problems/object-keys/problem_zh-cn.md index 09d67ae1..1b07c63f 100644 --- a/problems/object-keys/problem_zh-cn.md +++ b/problems/object-keys/problem_zh-cn.md @@ -1,5 +1,44 @@ ---- +JavaScript provides a native way of listing all the available keys of an object. This can be helpful for looping through all the properties of an object and manipulating their values accordingly. -# +Here's an example of listing all object keys using the **Object.keys()** +prototype method. ---- +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +The above code will print an array of strings, where each string is a key in the car object. `['make', 'model', 'year']` + +## The challenge: + +Create a file named `object-keys.js`. + +In that file, define a variable named `car` like this: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Then define another variable named `keys` like this: +```js +const keys = Object.keys(car) +``` + +Use `console.log()` to print the `keys` variable to the terminal. + +Check to see if your program is correct by running this command: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/problem_zh-tw.md b/problems/object-keys/problem_zh-tw.md new file mode 100644 index 00000000..1b07c63f --- /dev/null +++ b/problems/object-keys/problem_zh-tw.md @@ -0,0 +1,44 @@ +JavaScript provides a native way of listing all the available keys of an object. This can be helpful for looping through all the properties of an object and manipulating their values accordingly. + +Here's an example of listing all object keys using the **Object.keys()** +prototype method. + +```js +const car = { + make: 'Toyota', + model: 'Camry', + year: 2020 +} +const keys = Object.keys(car) + +console.log(keys) +``` + +The above code will print an array of strings, where each string is a key in the car object. `['make', 'model', 'year']` + +## The challenge: + +Create a file named `object-keys.js`. + +In that file, define a variable named `car` like this: + +```js +const car = { + make: 'Honda', + model: 'Accord', + year: 2020 +} +``` + +Then define another variable named `keys` like this: +```js +const keys = Object.keys(car) +``` + +Use `console.log()` to print the `keys` variable to the terminal. + +Check to see if your program is correct by running this command: + +```bash +javascripting verify object-keys.js +``` diff --git a/problems/object-keys/solution.md b/problems/object-keys/solution.md index 09d67ae1..0f3540ea 100644 --- a/problems/object-keys/solution.md +++ b/problems/object-keys/solution.md @@ -1,5 +1,11 @@ --- -# +# CORRECT. + +Good job using the Object.keys() prototype method. Remember to use it when you need to list the keys of an object. + +The next challenge is all about **functions**. + +Run `javascripting` in the console to choose the next challenge. --- diff --git a/problems/object-keys/solution_es.md b/problems/object-keys/solution_es.md index 09d67ae1..773f3d47 100644 --- a/problems/object-keys/solution_es.md +++ b/problems/object-keys/solution_es.md @@ -1,5 +1,11 @@ --- -# +# CORRECTO. + +Buen trabajo usando el método Object.keys(). Recuerda usarlo cuando necesites listar las propiedades de un objeto. + +El próximo ejercicio trabajaremos con **funciones**. + +Ejecuta `javascripting` en la consola para seleccionar el siguiente ejercicio. --- diff --git a/problems/object-keys/solution_fr.md b/problems/object-keys/solution_fr.md new file mode 100644 index 00000000..3eb423b0 --- /dev/null +++ b/problems/object-keys/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# CORRECT. + +Bon travail avec la méthode du prototype Object.keys(). N'oubliez pas de l'utiliser lorsque vous devez lister les clés d'un objet. + +Le prochain défi portera sur les **functions**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/object-keys/solution_it.md b/problems/object-keys/solution_it.md new file mode 100644 index 00000000..3f2e19fe --- /dev/null +++ b/problems/object-keys/solution_it.md @@ -0,0 +1,11 @@ +--- + +# CORRETTO. + +Ottimo lavoro con il metodo prototipo Object.keys (). Ricorda di usarlo quando devi elencare le chiavi di un oggetto. + +La prossima sfida riguarda le ** funzioni **. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/object-keys/solution_ja.md b/problems/object-keys/solution_ja.md index 09d67ae1..94ed0138 100644 --- a/problems/object-keys/solution_ja.md +++ b/problems/object-keys/solution_ja.md @@ -1,5 +1,11 @@ --- -# +# よろしい. ---- +Object.keys()を使用することで,キーをうまく表示させることができました.オブジェクトのキーを列挙する必要があるときは,この方法を思い出してください. + +次の課題は関数です. + +コンソールで `javascripting` コマンドを実行します.次の課題を選択しましょう. + +--- \ No newline at end of file diff --git a/problems/object-keys/solution_ko.md b/problems/object-keys/solution_ko.md index 09d67ae1..0f3540ea 100644 --- a/problems/object-keys/solution_ko.md +++ b/problems/object-keys/solution_ko.md @@ -1,5 +1,11 @@ --- -# +# CORRECT. + +Good job using the Object.keys() prototype method. Remember to use it when you need to list the keys of an object. + +The next challenge is all about **functions**. + +Run `javascripting` in the console to choose the next challenge. --- diff --git a/problems/object-keys/solution_nb-no.md b/problems/object-keys/solution_nb-no.md new file mode 100644 index 00000000..0f3540ea --- /dev/null +++ b/problems/object-keys/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# CORRECT. + +Good job using the Object.keys() prototype method. Remember to use it when you need to list the keys of an object. + +The next challenge is all about **functions**. + +Run `javascripting` in the console to choose the next challenge. + +--- diff --git a/problems/object-keys/solution_nl.md b/problems/object-keys/solution_nl.md new file mode 100644 index 00000000..1e2d385b --- /dev/null +++ b/problems/object-keys/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# CORRECT. + +Je hebt de Object.keys() prototype method correct gebruikt. Onthoud dat je deze method kunt gebruiken als je de keys van object wilt opvragen. + +De volgende uitdaging gaat over **functions**. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/object-keys/solution_pt-br.md b/problems/object-keys/solution_pt-br.md new file mode 100644 index 00000000..52b56ae2 --- /dev/null +++ b/problems/object-keys/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# CORRETO. + +Bom trabalho utilizando o método Object.keys(). Lembre-se de utilizar ele quando você precisar listas as propriedades de um objeto. + +O próximo desafio será sobre **functions**. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/object-keys/solution_ru.md b/problems/object-keys/solution_ru.md new file mode 100644 index 00000000..98a93de3 --- /dev/null +++ b/problems/object-keys/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ВЕРНО. + +Хорошая работа с использованием метода-прототипа Object.keys(). Не забывайте использовать его, когда вам нужно перечислить ключи объекта. + +В следующем упражнении всё о **функциях**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/object-keys/solution_uk.md b/problems/object-keys/solution_uk.md new file mode 100644 index 00000000..87da95ba --- /dev/null +++ b/problems/object-keys/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ВІРНО. + +Гарна робота з використанням методу прототипу Object.keys(). Не забувайте використовувати його, коли вам потрібно перелічити ключі об’єкта. + +Наступне завдання буде виключно про **функції**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/object-keys/solution_zh-cn.md b/problems/object-keys/solution_zh-cn.md index 09d67ae1..0f3540ea 100644 --- a/problems/object-keys/solution_zh-cn.md +++ b/problems/object-keys/solution_zh-cn.md @@ -1,5 +1,11 @@ --- -# +# CORRECT. + +Good job using the Object.keys() prototype method. Remember to use it when you need to list the keys of an object. + +The next challenge is all about **functions**. + +Run `javascripting` in the console to choose the next challenge. --- diff --git a/problems/object-keys/solution_zh-tw.md b/problems/object-keys/solution_zh-tw.md new file mode 100644 index 00000000..0f3540ea --- /dev/null +++ b/problems/object-keys/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# CORRECT. + +Good job using the Object.keys() prototype method. Remember to use it when you need to list the keys of an object. + +The next challenge is all about **functions**. + +Run `javascripting` in the console to choose the next challenge. + +--- diff --git a/problems/object-properties/index.js b/problems/object-properties/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/object-properties/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/object-properties/problem.md b/problems/object-properties/problem.md index f44ec2f6..0b829609 100644 --- a/problems/object-properties/problem.md +++ b/problems/object-properties/problem.md @@ -1,17 +1,13 @@ ---- - -# OBJECT PROPERTIES - You can access and manipulate object properties –– the keys and values that an object contains –– using a method very similar to arrays. Here's an example using **square brackets**: ```js -var example = { +const example = { pizza: 'yummy' -}; +} -console.log(example['pizza']); +console.log(example['pizza']) ``` The above code will print the string `'yummy'` to the terminal. @@ -19,9 +15,9 @@ The above code will print the string `'yummy'` to the terminal. Alternately, you can use **dot notation** to get identical results: ```js -example.pizza; +example.pizza -example['pizza']; +example['pizza'] ``` The two lines of code above will both return `yummy`. @@ -33,15 +29,15 @@ Create a file named `object-properties.js`. In that file, define a variable named `food` like this: ```js -var food = { +const food = { types: 'only pizza' -}; +} ``` Use `console.log()` to print the `types` property of the `food` object to the terminal. Check to see if your program is correct by running this command: -`javascripting verify object-properties.js` - ---- +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_es.md b/problems/object-properties/problem_es.md index 16ff0a5b..8edd16dc 100644 --- a/problems/object-properties/problem_es.md +++ b/problems/object-properties/problem_es.md @@ -1,30 +1,26 @@ ---- - -# PROPIEDADES DE OBJETOS - Puedes acceder y manipular propiedades de objetos –– las **llaves** y **valores** que un objeto contiene –– utilizando una forma muy similar que con arrays. Un ejemplo usando **corchetes**: ```js -var example = { +const example = { pizza: 'yummy' -}; +} -console.log(example['pizza']); +console.log(example['pizza']) ``` -El código anterior imprimirá la string `yummy` al a terminal. +El código anterior imprimirá el string `yummy` en la terminal. -Alternativamente, puedes usar la **notación de punto** para obtener resultados idénticos: +También puedes usar la **notación de punto** para obtener resultados idénticos: ```js -example.pizza; +example.pizza -example['pizza']; +example['pizza'] ``` -La dos líneas de código anteriores retornaran `yummy`. +Las dos líneas de código anteriores retornarán `yummy`. ## El ejercicio: @@ -33,15 +29,15 @@ Crea un archivo llamado `object-properties.js`. En ese archivo, define una variable llamada `food` de la siguiente forma: ```js -var food = { +const food = { types: 'only pizza' -}; +} ``` -Utiliza `console.log()` para imprimir la propiedad `types` del objeto `food` a la terminal. +Utiliza `console.log()` para imprimir la propiedad `types` del objeto `food` en la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify object-properties.js` - ---- +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_fr.md b/problems/object-properties/problem_fr.md new file mode 100644 index 00000000..137ba20e --- /dev/null +++ b/problems/object-properties/problem_fr.md @@ -0,0 +1,43 @@ +Vous pouvez manipuler les propriétés d'objets — les clés et valeurs qu'un objet contient — en utilisant des méthodes très similaires aux tableaux. + +Voici un example utilisant des **crochets** : + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +Le code ci-dessus va afficher la chaine de caractères `yummy` dans le terminal. + +Une alternative consiste à utiliser la **notation en point** pour avoir le même résultat : + +```js +example.pizza + +example['pizza'] +``` + +Les deux lignes de code ci-dessus renverront `yummy`. + +## Le défi : + +Créez un fichier nommé `proprietes-objet.js`. + +Dans ce fichier, définissez une variable nommée `food` comme ceci : + +```js +const food = { + types: 'only pizza' +} +``` + +Utilisez `console.log()` pour afficher la propriété `types` de l'objet `food` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify proprietes-objet.js +``` diff --git a/problems/object-properties/problem_it.md b/problems/object-properties/problem_it.md new file mode 100644 index 00000000..d3e04875 --- /dev/null +++ b/problems/object-properties/problem_it.md @@ -0,0 +1,43 @@ +Puoi accedere e manipolare proprietà degli oggetti –– le chiavi e i valori contenuti da un oggetto –– usando un metodo molto simile agli array. + +Ecco un esempio usando le **parentesi quadre**: + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +Il codice precedente stamperà la stringa `'yummy'` sul terminale. + +In alternativa, puoi usare la **notazione puntata** per ottenere un risultato identico: + +```js +example.pizza + +example['pizza'] +``` + +Le due righe di codice precedenti restituiranno entrambe `yummy`. + +## La sfida: + +Crea un file dal nome `object-properties.js`. + +In questo file, definisci una variabile chiamata `food` come segue: + +```js +const food = { + types: 'only pizza' +} +``` + +Usa `console.log()` per stampare la proprietà `types` dell'oggetto `food` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_ja.md b/problems/object-properties/problem_ja.md index 46e0ca8a..fbe9add5 100644 --- a/problems/object-properties/problem_ja.md +++ b/problems/object-properties/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# オブジェクトのプロパティ - オブジェクトのプロパティの値を取得したり変更したりできます。 プロパティはオブジェクトに含まれるキーと値の組み合わせです。 オブジェクトのプロパティは配列とよく似た方法で操作します。 @@ -9,11 +5,11 @@ 次の例のように角括弧を使います... ```js -var example = { +const example = { pizza: 'yummy' -}; +} -console.log(example['pizza']); +console.log(example['pizza']) ``` 上のコードは、 `'yummy'` とターミナルに出力します。 @@ -21,9 +17,9 @@ console.log(example['pizza']); 別のやりかたとして、ドット記法を使って同じ結果を得ることもできます... ```js -example.pizza; +example.pizza -example['pizza']; +example['pizza'] ``` 上の二つの行は、両方とも `yummy` という値を返します。 @@ -37,15 +33,15 @@ example['pizza']; ファイルの中で、変数 `food` を次のように定義してください... ```js -var food = { +const food = { types: 'only pizza' -}; +} ``` `console.log()` を使って、 `food` オブジェクトの `types` プロパティをターミナルに表示しましょう。 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify object-properties.js` - ---- +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_ko.md b/problems/object-properties/problem_ko.md index 91c6f345..634166b6 100644 --- a/problems/object-properties/problem_ko.md +++ b/problems/object-properties/problem_ko.md @@ -1,17 +1,13 @@ ---- - -# 객체 속성 - 배열과 매우 비슷한 방법으로 객체의 속성(객체가 가지고 있는 키와 값)에 접근하고 그를 조작할 수 있습니다. **대괄호**를 사용하는 예제입니다. ```js -var example = { +const example = { pizza: 'yummy' -}; +} -console.log(example['pizza']); +console.log(example['pizza']) ``` 위의 코드는 문자열 `'yummy'`를 터미널에 출력합니다. @@ -19,9 +15,9 @@ console.log(example['pizza']); 아니면, **점(.) 구문**으로 같은 결과를 얻을 수 있습니다. ```js -example.pizza; +example.pizza -example['pizza']; +example['pizza'] ``` 위에 있는 두 줄의 코드는 양쪽 다 `yummy`를 반환합니다. @@ -33,15 +29,15 @@ example['pizza']; 파일 안에서 `food`라는 변수를 이렇게 정의합니다. ```js -var food = { +const food = { types: 'only pizza' -}; +} ``` `console.log()`를 사용해 `food` 객체의 `types` 속성을 터미널에 출력합니다. 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify object-properties.js` - ---- +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_nb-no.md b/problems/object-properties/problem_nb-no.md new file mode 100644 index 00000000..c030990c --- /dev/null +++ b/problems/object-properties/problem_nb-no.md @@ -0,0 +1,43 @@ +Du kan bruke og endre objektegenskaper –– nøklene og verdiene et objekt inneholder –– svært likt som arrayer. + +Her er et eksempel som bruker **hakeparantes**: + +```js +const eksempel = { + pizza: 'yummy' +} + +console.log(eksempel['pizza']) +``` + +Koden over skriver ut stringen `'yummy'` til skjermen. + +Alternativt kan du bruke **punktum notasjon** for samme resultat: + +```js +eksempel.pizza + +eksempel['pizza'] +``` + +De to linjene over returnerer `yummy` begge to. + +## Oppgaven: + +Lag en fil som heter `object-properties.js`. + +Definer en variabel med navnet `food` i den filen: + +```js +const food = { + types: 'only pizza' +} +``` + +Bruk `console.log()` til å skrive ut `types` egenskapen av `food` objektet til skjermen. + +Se om programmet ditt er riktig ved å kjøre denne kommandoen: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_nl.md b/problems/object-properties/problem_nl.md new file mode 100755 index 00000000..b731d17a --- /dev/null +++ b/problems/object-properties/problem_nl.md @@ -0,0 +1,43 @@ +Het benaderen en aanpassen van object eigenschappen –– de keys en values die het object bevat –– doe je met een methode die lijkt op de array manier. + +Hier is een voorbeeld met **blokhaken**: + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +Deze code print de string `'yummy'` naar de console. + +Daarnaast kun je ook de **dot notatie** gebruiken met hetzelfde resultaat. + +```js +example.pizza + +example['pizza'] +``` + +Deze twee regels code geven allebei `yummy` als resultaat. + +## De uitdaging + +Maak een nieuw bestand met de naam `object-properties.js`. + +Definieer in dit bestand een nieuwe variabele met de naam `food` zoals hieronder: + +```js +const food = { + types: 'only pizza' +} +``` + +Gebruik `console.log()` om de `types` eigenschap van het `food` object naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_pt-br.md b/problems/object-properties/problem_pt-br.md new file mode 100644 index 00000000..2014f3cd --- /dev/null +++ b/problems/object-properties/problem_pt-br.md @@ -0,0 +1,43 @@ +Você pode acessar e manipular propriedades de objetos –– as chaves e valores de um objeto –– de uma maneira bem similar como fazemos com arrays. + +Aqui está um exemplo usando **colchetes**: + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +O código acima vai imprimir no terminal a string `'yummy'`. + +Como alternativa você pode utilizar **ponto** para obter o mesmo resultado: + +```js +example.pizza + +example['pizza'] +``` + +As duas linhas de código acima retornarão `yummy`. + +## Desafio: + +Crie um arquivo chamado `object-properties.js`. + +Neste arquivo, defina uma variável chamada `food` desta maneira: + +```js +const food = { + types: 'only pizza' +} +``` + +Use o `console.log()` para imprimir a propriedade `types` do objeto `food` no terminal. + +Verifique se o seu programa está correto usando o comando: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_ru.md b/problems/object-properties/problem_ru.md new file mode 100644 index 00000000..d97a74c1 --- /dev/null +++ b/problems/object-properties/problem_ru.md @@ -0,0 +1,43 @@ +Вы можете получить доступ и оперировать свойствами объектов -- ключами и значениями, которые содержит объект -- используя синтаксис, очень похожий на работу с массивами. + +Вот пример использования **квадратных скобок**: + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +Код приведенный выше выведет в терминал строку `'yummy'`. + +В качестве альтернативы, вы можете использовать **запись с точкой** и получить идентичный результат: + +```js +example.pizza + +example['pizza'] +``` + +Обе строки кода, приведенные выше, вернут одинаковое значение `yummy`. + +## Условие задачи: + +Создайте файл `object-properties.js`. + +В этом файле объявите следующим образом переменную `food`: + +```js +const food = { + types: 'only pizza' +} +``` + +Используйте `console.log()` и выведите в терминал свойство `types` объекта `food`. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_uk.md b/problems/object-properties/problem_uk.md new file mode 100644 index 00000000..ef524dd2 --- /dev/null +++ b/problems/object-properties/problem_uk.md @@ -0,0 +1,43 @@ +Ви можете отримувати значення та маніпулювати властивостями об’єктів –– ключами та значеннями, які містить об’єкт –– схожим методом, як і у масивів. + +Це приклад з **квадратними дужками**: + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +Код вище виведе рядок `'yummy'` до терміналу. + +Окрім того, ви можете використати **крапковий запис (dot notation)**, щоб отримати ідентичний результат: + +```js +example.pizza + +example['pizza'] +``` + +Обидва рядки коду повернуть `yummy`. + +## Завдання: + +Створити файл `object-properties.js`. + +У цьому файлі оголосити змінну під назвою `food` ось так: + +```js +const food = { + types: 'only pizza' +} +``` + +Використайте `console.log()`, щоб вивести властивість `types` об’єкту `food` до терміналу. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_zh-cn.md b/problems/object-properties/problem_zh-cn.md index c01baf72..b0b9382d 100644 --- a/problems/object-properties/problem_zh-cn.md +++ b/problems/object-properties/problem_zh-cn.md @@ -1,17 +1,13 @@ ---- - -# 对象的属性 - 你可以使用与访问和操作数组非常类似的方法来访问和操作对象的属性——属性就是对象所包含的键和值的对。 这里是一个使用**方括号**的例子: ```js -var example = { +const example = { pizza: 'yummy' -}; +} -console.log(example['pizza']); +console.log(example['pizza']) ``` 上面的例子将打印出 `'yummy'` 到终端。 @@ -19,9 +15,9 @@ console.log(example['pizza']); 你也可以使用**英文句号**来得到相同的结果: ```js -example.pizza; +example.pizza -example['pizza']; +example['pizza'] ``` 上面的两行代码都会返回 `yummy`。 @@ -33,15 +29,15 @@ example['pizza']; 在文件中,像这样定义名为 `food` 的变量: ```js -var food = { +const food = { types: 'only pizza' -}; +} ``` 使用 `console.log()` 打印 `food` 对象的 `types` 属性到终端。 运行下面的命令来检查你的程序是否正确: -`javascripting verify object-properties.js` - ---- +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/problem_zh-tw.md b/problems/object-properties/problem_zh-tw.md new file mode 100644 index 00000000..9111183c --- /dev/null +++ b/problems/object-properties/problem_zh-tw.md @@ -0,0 +1,43 @@ +你可以使用與存取和操作陣列非常類似的方法來存取和操作物件的屬性——屬性就是物件所包含的鍵和值的對。 + +這裡是一個使用**中括號**的例子: + +```js +const example = { + pizza: 'yummy' +} + +console.log(example['pizza']) +``` + +上面的例子將印出 `'yummy'` 到終端機上。 + +你也可以使用**點**來得到相同的結果: + +```js +example.pizza + +example['pizza'] +``` + +上面的兩行程式碼都會返回 `yummy`。 + +## 挑戰: + +建立一個名為 `object-properties.js` 的檔案。 + +在該檔案中,像這樣定義一個名為 `food` 的變數: + +```js +const food = { + types: 'only pizza' +} +``` + +使用 `console.log()` 印出 `food` 物件的 `types` 屬性到終端機上。 + +執行下面的命令來檢查你寫的程式是否正確: + +```bash +javascripting verify object-properties.js +``` diff --git a/problems/object-properties/solution.md b/problems/object-properties/solution.md index f256ee27..981974ef 100644 --- a/problems/object-properties/solution.md +++ b/problems/object-properties/solution.md @@ -4,7 +4,7 @@ Good job accessing that property. -The next challenge is all about **functions**. +The next challenge is all about **object keys**. Run `javascripting` in the console to choose the next challenge. diff --git a/problems/object-properties/solution_es.md b/problems/object-properties/solution_es.md index 31a6fcbc..e4b2b60a 100644 --- a/problems/object-properties/solution_es.md +++ b/problems/object-properties/solution_es.md @@ -1,10 +1,10 @@ --- -# CORRECTO! LOS HIPSTERS TIENEN SU PROPIO TIPO DE BICICLETAS +# CORRECTO! PIZZA ES LA ÚNICA COMIDA Buen trabajo accediendo a esa propiedad. -El siguiente ejercicio es completamente acerca de **funciones**. +El siguiente ejercicio es completamente acerca de **llaves de objetos**. Ejecuta `javascripting` en la consola para seleccionar el siguiente ejercicio. diff --git a/problems/object-properties/solution_fr.md b/problems/object-properties/solution_fr.md new file mode 100644 index 00000000..8bfcb669 --- /dev/null +++ b/problems/object-properties/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# CORRECT. LA PIZZA Y A QUE ÇA DE VRAI. + +Vous avez réussi à accéder à la propriété. + +Le prochain défi parlera de **fonctions**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/object-properties/solution_it.md b/problems/object-properties/solution_it.md new file mode 100644 index 00000000..d1d43db2 --- /dev/null +++ b/problems/object-properties/solution_it.md @@ -0,0 +1,11 @@ +--- + +# CORRETTO. LA PIZZA È IL SOLO CIBO. + +Ottimo lavoro nell'accedere a quella proprietà. + +La prossima sfida è interamente centrata sulle **chiavi degli oggetti**. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/object-properties/solution_nb-no.md b/problems/object-properties/solution_nb-no.md new file mode 100644 index 00000000..f53c7b78 --- /dev/null +++ b/problems/object-properties/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# RIKTIG. PIZZA ER DEN ENESTE MATEN. + +Bra jobba med å bruke den egenskapen. + +Den neste oppgaven handler om **funksjoner**. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/object-properties/solution_nl.md b/problems/object-properties/solution_nl.md new file mode 100644 index 00000000..c45baa1e --- /dev/null +++ b/problems/object-properties/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# CORRECT. PIZZA IS THE ONLY FOOD. + +Goed gedaan. Je hebt de eigenschap van het object juist opgevraagd. + +De volgende uitdaging gaat over **object keys**. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/object-properties/solution_pt-br.md b/problems/object-properties/solution_pt-br.md new file mode 100644 index 00000000..95207662 --- /dev/null +++ b/problems/object-properties/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# CORRETO! PIZZA É O ÚNICO ALIMENTO. + +Bom trabalho ao acessar esta propriedade. + +O próximo desafio se trata de **funções**. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/object-properties/solution_ru.md b/problems/object-properties/solution_ru.md new file mode 100644 index 00000000..16bc7968 --- /dev/null +++ b/problems/object-properties/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ВЕРНО. ТОЛЬКО ПИЦЦА ЭТО ЕДА. + +Отличная работа по доступу к свойству объекта. + +В следующем упражнении всё о **ключах объекта**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/object-properties/solution_uk.md b/problems/object-properties/solution_uk.md new file mode 100644 index 00000000..097ae460 --- /dev/null +++ b/problems/object-properties/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ВІРНО. ТІЛЬКИ ПІЦА Є ЇЖЕЮ. + +Гарна робота з доступом до властивостей. + +Наступне завдання буде виключно про **ключі об'єкта**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/object-properties/solution_zh-tw.md b/problems/object-properties/solution_zh-tw.md new file mode 100644 index 00000000..d767ece1 --- /dev/null +++ b/problems/object-properties/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 正確,PIZZA 是目前唯一的食物。 + +你已經學會如何存取屬性了。 + +下一個挑戰是關於 **functions**,也就是**函式**。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/objects/index.js b/problems/objects/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/objects/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/objects/problem.md b/problems/objects/problem.md index 2d29b9d8..d2965dc4 100644 --- a/problems/objects/problem.md +++ b/problems/objects/problem.md @@ -1,13 +1,9 @@ ---- - -# OBJECTS - Objects are lists of values similar to arrays, except values are identified by keys instead of integers. Here is an example: ```js -var foodPreferences = { +const foodPreferences = { pizza: 'yum', salad: 'gross' } @@ -20,7 +16,7 @@ Create a file named `objects.js`. In that file, define a variable named `pizza` like this: ```js -var pizza = { +const pizza = { toppings: ['cheese', 'sauce', 'pepperoni'], crust: 'deep dish', serves: 2 @@ -31,7 +27,6 @@ Use `console.log()` to print the `pizza` object to the terminal. Check to see if your program is correct by running this command: -`javascripting verify objects.js` - - ---- +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_es.md b/problems/objects/problem_es.md index 7cc54585..98e73abe 100644 --- a/problems/objects/problem_es.md +++ b/problems/objects/problem_es.md @@ -1,16 +1,11 @@ ---- - -# OBJETOS - Los objetos son en cierta forma contenedores y se los puede pensar cómo diccionarios. Tendrá ciertas **llaves** y cada una se verá referenciada a un **valor**. - Por ejemplo: ```js -var foodPreferences = { +const foodPreferences = { pizza: 'yum', salad: 'gross' } @@ -25,7 +20,7 @@ Crea un archivo llamado `objects.js`. En ese archivo, define una variable llamada `pizza` de la siguiente forma: ```js -var pizza = { +const pizza = { toppings: ['cheese', 'sauce', 'pepperoni'], crust: 'deep dish', serves: 2 @@ -36,6 +31,6 @@ Utiliza `console.log()` para imprimir el objeto `pizza` a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: -`javascripting verify objects.js` - ---- +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_fr.md b/problems/objects/problem_fr.md new file mode 100644 index 00000000..c4dc6dcc --- /dev/null +++ b/problems/objects/problem_fr.md @@ -0,0 +1,32 @@ +Les objets sont des listes de valeurs similaires aux tableaux, sauf que les valeurs sont identifiées par une clé au lieu d'un entier. + +Voici un exemple : + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## Le défi : + +Créez un fichier nommé `objets.js`. + +Dans ce fichier, définissez une variable nommée `pizza` comme celà : + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Utilisez `console.log()` pour afficher l'objet `pizza` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify objets.js +``` diff --git a/problems/objects/problem_it.md b/problems/objects/problem_it.md new file mode 100644 index 00000000..e48cc127 --- /dev/null +++ b/problems/objects/problem_it.md @@ -0,0 +1,32 @@ +Gli oggetti sono liste di valori simili agli array, con l'eccezione che i valori sono identificati tramite chiavi anziché numeri interi. + +Ecco un esempio + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## La sfida: + +Crea un file dal nome `objects.js`. + +In questo file, definisci una variabile chiamata `pizza` come segue: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Usa `console.log()` per stampare l'oggetto `pizza` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_ja.md b/problems/objects/problem_ja.md index bcd64a24..6ab16eef 100644 --- a/problems/objects/problem_ja.md +++ b/problems/objects/problem_ja.md @@ -1,14 +1,10 @@ ---- - -# オブジェクト - オブジェクトは、配列に似た値のリストです。配列と違い、各要素を整数ではなくキーで識別します。 たとえば... ```js -var foodPreferences = { +const foodPreferences = { pizza: 'yum', salad: 'gross' } @@ -23,7 +19,7 @@ var foodPreferences = { ファイルの中で、変数 `pizza` を次のようにして定義してください... ```js -var pizza = { +const pizza = { toppings: ['cheese', 'sauce', 'pepperoni'], crust: 'deep dish', serves: 2 @@ -34,6 +30,6 @@ var pizza = { 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう... -`javascripting verify objects.js` - ---- +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_ko.md b/problems/objects/problem_ko.md index 0cf56b3e..268e3166 100644 --- a/problems/objects/problem_ko.md +++ b/problems/objects/problem_ko.md @@ -1,13 +1,9 @@ ---- - -# 객체 - 객체는 배열과 비슷한 값의 목록입니다. 배열과 다른 점은 정수 대신 키를 사용해 값을 확인하는 점입니다. 예제를 보세요. ```js -var foodPreferences = { +const foodPreferences = { pizza: 'yum', salad: 'gross' } @@ -20,7 +16,7 @@ var foodPreferences = { 파일 안에서 이렇게 `pizza`라는 변수를 정의합니다. ```js -var pizza = { +const pizza = { toppings: ['cheese', 'sauce', 'pepperoni'], crust: 'deep dish', serves: 2 @@ -31,7 +27,6 @@ var pizza = { 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify objects.js` - - ---- +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_nb-no.md b/problems/objects/problem_nb-no.md new file mode 100644 index 00000000..e0844efc --- /dev/null +++ b/problems/objects/problem_nb-no.md @@ -0,0 +1,32 @@ +Objekter er en samling verdier som arrayer, bortsett ifra at verdiene er identifisert med nøkler istedefor tall. + +Her er et eksempel: + +```js +const favorittMat = { + pizza: 'nam', + salat: 'fysjameg' +} +``` + +## Oppgaven: + +Lag en fil som heter `objects.js`. + +Definer en variabel `pizza` i den filen: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Bruk `console.log()` for å skrive ut `pizza` objektet til skjermen. + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_nl.md b/problems/objects/problem_nl.md new file mode 100755 index 00000000..cd40872f --- /dev/null +++ b/problems/objects/problem_nl.md @@ -0,0 +1,32 @@ +Objecten zijn lijsten met waarden die lijken op arrays, alleen worden de waarden niet met een numerieke index opgevraagd maar met een key (sleutel). + +Hier is een voorbeeld: + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## De uitdaging: + +Maak een nieuw bestand met de naam `objects.js`. + +Definieer in dit bestand een variable met de naam `pizza`: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Gebruik `console.log()` om het `pizza` object naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_pt-br.md b/problems/objects/problem_pt-br.md new file mode 100644 index 00000000..8bf947a2 --- /dev/null +++ b/problems/objects/problem_pt-br.md @@ -0,0 +1,32 @@ +Um objetos é uma lista de valores similar á um array, exceto que seus valores são identificados por chaves ao invés de inteiros. + +Aqui está um exemplo: + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## Desafio: + +Crie um arquivo chamado `objects.js`. + +Neste arquivo, defina uma variável chamada `pizza` desta forma: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Use o `console.log()` para imprimir o objeto `pizza` no terminal. + +Verifique se o seu programa está correto usando este comando: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_ru.md b/problems/objects/problem_ru.md new file mode 100644 index 00000000..4c9b0056 --- /dev/null +++ b/problems/objects/problem_ru.md @@ -0,0 +1,32 @@ +Объекты - это списки значений, почти как в массивах, за исключением того, что значениям соответствуют ключи, а не числа. + +Например: + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## Условие задачи: + +Создайте файл `objects.js`. + +В этом файле объявите следующим образом переменную `pizza`: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Используйте `console.log()` и введите в терминал объект `pizza`. + +Чтобы удостовериться в правильности решения задачи, запустите в терминале следующую команду: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_uk.md b/problems/objects/problem_uk.md new file mode 100644 index 00000000..41dd7f95 --- /dev/null +++ b/problems/objects/problem_uk.md @@ -0,0 +1,32 @@ +Об’єкти (Objects) — це списки значень, схожі на масиви, за винятком того, що значення ідентифікуються з допомогою ключових слів (keys) замість цілих чисел. + +Приклад: + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## Завдання: + +Створити файл `objects.js`. + +У цьому файлі, оголосіть змінну `pizza` ось так: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +Використайте `console.log()`, щоб вивести об’єкт `pizza` до терміналу. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_zh-cn.md b/problems/objects/problem_zh-cn.md index f7c19161..9dd7006e 100644 --- a/problems/objects/problem_zh-cn.md +++ b/problems/objects/problem_zh-cn.md @@ -1,13 +1,9 @@ ---- - -# 对象 - 对象像数组一样,也是一组值的集合,所不同是,对象里的值被关键字所标识,而非整数。 例子: ```js -var foodPreferences = { +const foodPreferences = { pizza: 'yum', salad: 'gross' } @@ -20,7 +16,7 @@ var foodPreferences = { 在文件里,像这样定义一个变量 `pizza`: ```js -var pizza = { +const pizza = { toppings: ['cheese', 'sauce', 'pepperoni'], crust: 'deep dish', serves: 2 @@ -31,7 +27,6 @@ var pizza = { 运行下面的命令检查你的程序是否正确: -`javascripting verify objects.js` - - ---- +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/problem_zh-tw.md b/problems/objects/problem_zh-tw.md new file mode 100644 index 00000000..0652ae93 --- /dev/null +++ b/problems/objects/problem_zh-tw.md @@ -0,0 +1,32 @@ +物件像陣列一樣,也是一組值的集合,但不同的是,物件裡的值被鍵(Key)所標識,而非整數。 + +範例: + +```js +const foodPreferences = { + pizza: 'yum', + salad: 'gross' +} +``` + +## 挑戰: + +建立一個名為 `objects.js` 的檔案。 + +在該檔案裡,像這樣定義一個變數 `pizza`: + +```js +const pizza = { + toppings: ['cheese', 'sauce', 'pepperoni'], + crust: 'deep dish', + serves: 2 +} +``` + +使用 `console.log()` 印出 `pizza` 物件到終端機上。 + +執行下面的命令檢查你寫的程式是否正確: + +```bash +javascripting verify objects.js +``` diff --git a/problems/objects/solution_fr.md b/problems/objects/solution_fr.md new file mode 100644 index 00000000..5ad8972c --- /dev/null +++ b/problems/objects/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# L'OBJET PIZZA EST PRÊT. + +Vous avez réussi à créer un objet ! + +Dans le prochain défi, nous nous focaliserons sur l'accès à des propriétés d'objets. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/objects/solution_it.md b/problems/objects/solution_it.md new file mode 100644 index 00000000..2542c811 --- /dev/null +++ b/problems/objects/solution_it.md @@ -0,0 +1,11 @@ +--- + +# L'OGGETTO PIZZA È ANDATO. + +Hai creato un oggetto con successo! + +Nella prossima sfida ci occuperemo su come accedere alle proprietà degli oggetti. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/objects/solution_nb-no.md b/problems/objects/solution_nb-no.md new file mode 100644 index 00000000..41b7b9ac --- /dev/null +++ b/problems/objects/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# PIZZA OBJEKTET ER I ORDEN. + +Du greide å lage et objekt! + +I den neste oppgaven vil vi fokusere på å bruke objektets egenskaper. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/objects/solution_nl.md b/problems/objects/solution_nl.md new file mode 100644 index 00000000..8ecd0e4d --- /dev/null +++ b/problems/objects/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# PIZZA OBJECT IS GEMAAKT! + +Je hebt met succes een (pizza) object gemaakt! + +In de volgende uitdaging gaan we de properties van objecten onder de loep nemen. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/objects/solution_pt-br.md b/problems/objects/solution_pt-br.md new file mode 100644 index 00000000..3ee7e9e3 --- /dev/null +++ b/problems/objects/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# O OBJETO PIZZA FOI UMA BOA! + +Você criou um objeto com sucesso! + +No próximo desafio vamos ver como fazemos para acessar as propriedades de um objeto. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/objects/solution_ru.md b/problems/objects/solution_ru.md new file mode 100644 index 00000000..6694161b --- /dev/null +++ b/problems/objects/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ОБЪЕКТ ПИЦЦА УДАЛСЯ! + +Вы успешно создали объект! + +В следующем упражнении мы сосредоточимся на доступе к свойствам объекта. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/objects/solution_uk.md b/problems/objects/solution_uk.md new file mode 100644 index 00000000..2faf3224 --- /dev/null +++ b/problems/objects/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# PIZZA-ОБ'ЄКТ ВЖЕ ТУТ. + +Ви успішно створили об’єкт! + +В наступному завданні ми сфокусуємось на отриманні властивостей об’єкту. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/objects/solution_zh-tw.md b/problems/objects/solution_zh-tw.md new file mode 100644 index 00000000..ad9fcefd --- /dev/null +++ b/problems/objects/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 看到 PIZZA 物件了嗎? + +你成功地建立了一個物件! + +下一個挑戰我們將看到物件的屬性。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/revising-strings/index.js b/problems/revising-strings/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/revising-strings/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/revising-strings/problem.md b/problems/revising-strings/problem.md index 726cf55a..89ebe9d7 100644 --- a/problems/revising-strings/problem.md +++ b/problems/revising-strings/problem.md @@ -1,7 +1,3 @@ ---- - -# REVISING STRINGS - You will often need to change the contents of a string. Strings have built-in functionality that allow you to inspect and manipulate their contents. @@ -9,9 +5,9 @@ Strings have built-in functionality that allow you to inspect and manipulate the Here is an example using the `.replace()` method: ```js -var example = 'this example exists'; -example = example.replace('exists', 'is awesome'); -console.log(example); +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) ``` Note that to change the value that the `example` variable references, we need @@ -22,7 +18,7 @@ the right of the equals sign. Create a file named `revising-strings.js`. -Define a variable named `pizza` that references this string: `pizza is alright` +Define a variable named `pizza` that references this string: `'pizza is alright'` Use the `.replace()` method to change `alright` to `wonderful`. @@ -31,5 +27,3 @@ Use `console.log()` to print the results of the `.replace()` method to the termi Check to see if your program is correct by running this command: `javascripting verify revising-strings.js` - ---- diff --git a/problems/revising-strings/problem_es.md b/problems/revising-strings/problem_es.md index 80bd4b1f..77680b44 100644 --- a/problems/revising-strings/problem_es.md +++ b/problems/revising-strings/problem_es.md @@ -1,7 +1,3 @@ ---- - -# MODIFICANDO STRINGS - A menudo necesitarás cambiar el contenido de una string. Las strings tienen una funcionalidad por defecto que te permite reemplazar caracteres. @@ -9,9 +5,9 @@ Las strings tienen una funcionalidad por defecto que te permite reemplazar carac Por ejemplo a continuación veremos un uso del método `.replace()`: ```js -var example = 'this example exists'; -example = example.replace('exists', 'is awesome'); -console.log(example); +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) ``` Nota que para cambiar el valor que la variable `example` referencia, @@ -22,7 +18,7 @@ del método `example.replace()` del lado derecho del signo. Crea un archivo llamado `revising-strings.js`. -Define una variable llamada `pizza` que referencie esta string: `pizza is alright` +Define una variable llamada `pizza` que referencie esta string: `'pizza is alright'` Utiliza el método `.replace()` para cambiar `alright` con `wonderful`. @@ -31,5 +27,3 @@ Luego, utiliza `console.log()` para imprimir los resultados del método `.replac Comprueba si tu programa es correcto ejecutando el siguiente comando: `javascripting verify revising-strings.js` - ---- diff --git a/problems/revising-strings/problem_fr.md b/problems/revising-strings/problem_fr.md new file mode 100644 index 00000000..deaa5077 --- /dev/null +++ b/problems/revising-strings/problem_fr.md @@ -0,0 +1,27 @@ +Vous allez souvent avoir besoin de changer le contenu d'une chaîne de caractères. + +Les chaînes de caractères ont des fonctionnalités directement intégrées qui vous permettent de manipuler leur contenu. + +Voici un exemple qui utilise la méthode `.replace()` : + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +Notez que pour modifier la valeur contenue dans la variable `example`, nous devons utiliser encore une fois le signe égal, mais cette fois avec la méthode `example.replace()` à la droite du égal. + +## Le challenge : + +Créez un fichier nommé `revisions-chaines.js`. + +Définissez une variable nommée `pizza` qui contient cette chaîne de caractères : `'pizza is alright'` + +Utilisez la méthode `.replace()` pour modifier `alright` en `wonderful`. + +Utilisez `console.log()` pour afficher le résultat de la méthode `.replace()` dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +`javascripting verify revisions-chaines.js` diff --git a/problems/revising-strings/problem_it.md b/problems/revising-strings/problem_it.md new file mode 100644 index 00000000..b2986c69 --- /dev/null +++ b/problems/revising-strings/problem_it.md @@ -0,0 +1,29 @@ +Dovrai spesso cambiare il contenuto di una stringa. + +Le stringhe possiedono funzionalità integrata che ti permette di ispezionarne e manipolarne il contenuto. + +Ecco un esempio che usa il metodo `.replace()`: + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +Nota che per cambiare il valore referenziato dalla variabile `example`, dobbiamo usare +nuovamente il segno uguale, questa volta con il metodo `example.replace()` alla destra +del segno di uguaglianza. + +## La sfida: + +Crea un file dal nome `revising-strings.js`. + +Definisci una variabile dal nome `pizza` che referenzia la stringa: `'pizza is alright'` + +Usa il metodo `.replace()` per cambiare `alright` in `wonderful`. + +Usa `console.log()` per stampare il risultato del metodo `.replace()` sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +`javascripting verify revising-strings.js` diff --git a/problems/revising-strings/problem_ja.md b/problems/revising-strings/problem_ja.md index b7263d72..18340932 100644 --- a/problems/revising-strings/problem_ja.md +++ b/problems/revising-strings/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 文字列を変更 - 文字列の中身を書き換えたいことがあります。 文字列には用意された機能があります。文字列の中身を調べたり、書き換えたりできます。 @@ -9,9 +5,9 @@ たとえば `.replace()` メソッドは次のように使います... ```js -var example = 'this example exists'; -example = example.replace('exists', 'is awesome'); -console.log(example); +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) ``` 等号を使って `example` 変数を、もう一度変更することに注意してください。 @@ -21,7 +17,7 @@ console.log(example); `revising-strings.js` ファイルを作りましょう。 -ファイルの中で、文字列は `pizza is alright` を表す、変数 `pizza` を定義します。 +ファイルの中で、文字列は `'pizza is alright'` を表す、変数 `pizza` を定義します。 `.replace()` メソッドを使って、 `alright` を `wonderful` に変更します。 @@ -30,5 +26,3 @@ console.log(example); 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 `javascripting verify revising-strings.js` - ---- diff --git a/problems/revising-strings/problem_ko.md b/problems/revising-strings/problem_ko.md index f75bc85e..5e5bb12c 100644 --- a/problems/revising-strings/problem_ko.md +++ b/problems/revising-strings/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 문자열 뒤집기 - 문자열의 내용을 바꿀 경우가 종종 생깁니다. 문자열은 내용을 조작하고 살펴보는 내장 기능을 가지고 있습니다. @@ -9,9 +5,9 @@ `.replace()` 메소드를 사용하는 예제입니다. ```js -var example = 'this example exists'; -example = example.replace('exists', 'is awesome'); -console.log(example); +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) ``` `example` 변수가 참조하는 값을 바꾸는 것에 주의하세요. 등호를 다시 사용해야 합니다. 이번에는 `example.replace()` 메소드를 등호의 오른편에 두었습니다. @@ -20,7 +16,7 @@ console.log(example); `revising-strings.js`라는 파일을 만드세요. -`pizza is alright` 문자열을 참조하는 `pizza`라는 변수를 정의합니다. +`'pizza is alright'` 문자열을 참조하는 `pizza`라는 변수를 정의합니다. `.replace()` 메소드를 사용해 `alright`을 `wonderful`로 바꿉니다. @@ -29,5 +25,3 @@ console.log(example); 이 명령어를 실행해 프로그램이 올바른지 확인하세요. `javascripting verify revising-strings.js` - ---- diff --git a/problems/revising-strings/problem_nb-no.md b/problems/revising-strings/problem_nb-no.md new file mode 100644 index 00000000..27cbe546 --- /dev/null +++ b/problems/revising-strings/problem_nb-no.md @@ -0,0 +1,27 @@ +Du trenger ofte å endre innholdet av en string. + +Stringer har innebygd funksjonalitet som lar de manipulere og se på innholdet. + +Her er et eksempel som bruker `.replace()` metoden: + +```js +let example = 'dette eksemplet er kjedelig' +example = example.replace('kjedelig', 'kult') +console.log(example) +``` + +Merk deg at for å endre verdien variabelen `example` refererer til så bruker vi likhetstegnet. Denne gangen med `example.replace()` metoden på høyre siden av likhetstegnet. + +## Oppgaven: + +Lag en fil med navnet `revising-strings.js`. + +Deklarer en variabel, `pizza`, som refererer til strengen: `pizza is alright` + +Benytt `.replace()` metoden for å endre `alright` til `wonderful`. + +Bruk `console.log()` for å skrive ut resultatet av `.replace()` metoden til skjermen. + +Kontroller programmet ditt for å se om det er riktig ved å kjøre denne kommandoen: + +`javascripting verify revising-strings.js` diff --git a/problems/revising-strings/problem_nl.md b/problems/revising-strings/problem_nl.md new file mode 100755 index 00000000..bd51f7c3 --- /dev/null +++ b/problems/revising-strings/problem_nl.md @@ -0,0 +1,28 @@ +Je zult vaak de inhoud van een string moeten wijzigen. + +Strings hebben ingebouwde functionaliteit waarmee je hun inhoud kunt inspecteren en aanpassen. + +Hier is een voorbeeld waarbij de method`.replace()` wordt gebruikt: + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +Onthoud dat als je de waarde wilt aanpassen waar de `example` variabele naar verwijst, je opnieuw een "=" teken +moet gebruiken met de `example.replace()` method aan de rechterkant van het "=" teken. + +## De uitdaging: + +Maak een nieuw bestand met de naam `revising-strings.js`. + +Definieer een variabele met de naam `pizza` die verwijst naar de string: `'pizza is alright'` + +Gebruik de `.replace()` method om `alright` te veranderen in `wonderful`. + +Gebruik `console.log()` om het resultaat van de `.replace()` method naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +`javascripting verify revising-strings.js` diff --git a/problems/revising-strings/problem_pt-br.md b/problems/revising-strings/problem_pt-br.md new file mode 100644 index 00000000..ba7ed761 --- /dev/null +++ b/problems/revising-strings/problem_pt-br.md @@ -0,0 +1,29 @@ +Frequentemente você precisará mudar o conteúdo de uma string. + +As strings tem funcionalidades que te permitem inspecionar e manipular seus conteúdos. + +Aqui está um exemplo que usa o método `.replace()`: + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +Perceba que para mudar o valor da string da variável `example`, nós precisamos +usar o sinal `=` novamente, desta vez com o método `example.replace()` no lado +direito dele. + +## Desafio: + +Crie um arquivo chamado `revising-strings.js`. + +Defina uma variável chamada `pizza` que referencia esta string: `'pizza is alright'` + +Use o método `.replace()` para modificar o `alright` para `wonderful`. + +Use o `console.log()` para imprimir o resultado do método `.replace()` no terminal. + +Verifique se o seu programa está correto executando este comando: + +`javascripting verify revising-strings.js` diff --git a/problems/revising-strings/problem_ru.md b/problems/revising-strings/problem_ru.md new file mode 100644 index 00000000..493f4ce1 --- /dev/null +++ b/problems/revising-strings/problem_ru.md @@ -0,0 +1,29 @@ +Типовой задачей является изменение содержимого строки. + +Строки обладают функциональностью для проверки их содержимого и манипуляций над ним. + +Рассмотрим пример использования метода `.replace()`: + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +Обратите внимание: чтобы изменить значение переменной `example` нам нужно воспользоваться знаком _равно_ ещё раз, в этот раз вместе с вызовом метода `example.replace()` справа от знака _равно_. + +## Условие задачи: + +Создайте файл `revising-strings.js`. + +Объявите в нём переменную `pizza`, которой присвоено значение `'pizza is alright'`. + +Ипользуя метод `.replace()`, замените `alright` на `wonderful`. + +Воспользуйтесь командой `console.log()`, чтобы вывести результат работы метода `.replace()` в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify revising-strings.js +``` diff --git a/problems/revising-strings/problem_uk.md b/problems/revising-strings/problem_uk.md new file mode 100644 index 00000000..da15e969 --- /dev/null +++ b/problems/revising-strings/problem_uk.md @@ -0,0 +1,27 @@ +Часто необхідно буде змінювати вміст рядка. + +Рядки мають вбудований функціонал, що дозволяє вам переглядати та маніпулювати їх вмістом. + +Ось приклад використання методу `.replace()`: + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +Зверніть увагу, що для зміни значення змінної `example` ми повинні використати оператор присвоєння знову, цього разу з методом `example.replace()` праворуч від операторa присвоєння. + +## Завдання: + +Створити файл `revising-strings.js`. + +Оголосити змінну `pizza`, що вказуватиме на рядок: `'pizza is alright'` + +Використайте метод `.replace()`, щоб змінити `alright` на `wonderful`. + +Скористайтесь `console.log()`, щоб вивести результат роботи методу `.replace()` до терміналу. + +Перевірте вашу відповідь запустивши команду: + +`javascripting verify revising-strings.js` diff --git a/problems/revising-strings/problem_zh-cn.md b/problems/revising-strings/problem_zh-cn.md index 1dfa21c0..0804d792 100644 --- a/problems/revising-strings/problem_zh-cn.md +++ b/problems/revising-strings/problem_zh-cn.md @@ -1,7 +1,3 @@ ---- - -# 修改字符串 - 实际工作中可能经常需要修改一个字符串。 字符串中包含一些内建的功能允许你查看并修改它们的内容。 @@ -9,9 +5,9 @@ 这里是一个使用 `.replace()` 方法的例子: ```js -var example = 'this example exists'; -example = example.replace('exists', 'is awesome'); -console.log(example); +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) ``` 为了改变 `example` 变量引用的值,我们需要再一次使用等号。这一次出现在等号右边的是 `example.replace()` 方法。 @@ -20,7 +16,7 @@ console.log(example); 创建一个名为 `revising-strings.js` 的文件。 -定义一个名为 `pizza` 的变量,并且让它引用字符串 `pizza is alright`。 +定义一个名为 `pizza` 的变量,并且让它引用字符串 `'pizza is alright'`。 使用 `.replace()` 方法将 `alright` 替换为 `wonderful`。 @@ -29,5 +25,3 @@ console.log(example); 运行下面的命令来检查你的程序是否正确: `javascripting verify revising-strings.js` - ---- diff --git a/problems/revising-strings/problem_zh-tw.md b/problems/revising-strings/problem_zh-tw.md new file mode 100644 index 00000000..614800b6 --- /dev/null +++ b/problems/revising-strings/problem_zh-tw.md @@ -0,0 +1,27 @@ +實際工作中可能經常需要修改一個字串。 + +字串中包含一些內建的功能允許你查看並修改它們的內容。 + +這裡是一個使用 `.replace()` 方法的例子: + +```js +let example = 'this example exists' +example = example.replace('exists', 'is awesome') +console.log(example) +``` + +為了改變 `example` 變數引用的值,我們需要再一次使用等號。這一次出現在等號右邊的是 `example.replace()` 方法。 + +## 挑戰: + +建立一個名為 `revising-strings.js` 的檔案。 + +定義一個名為 `pizza` 的變數,並且賦予它字串 `'pizza is alright'`。 + +使用 `.replace()` 方法將 `alright` 替換為 `wonderful`。 + +用 `console.log()` 將 `.replace()` 方法的結果輸出到終端機上。 + +執行下面的命令來檢查你寫的程式是否正確: + +`javascripting verify revising-strings.js` diff --git a/problems/revising-strings/solution_fr.md b/problems/revising-strings/solution_fr.md new file mode 100644 index 00000000..6238dbdc --- /dev/null +++ b/problems/revising-strings/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# OUI, LA PIZZA C'EST _MERVEILLEUX_. + +Bon boulot avec cette méthode `.replace()` ! + +Nous allons ensuite étudier les **nombres**. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/revising-strings/solution_it.md b/problems/revising-strings/solution_it.md new file mode 100644 index 00000000..9f7c2fef --- /dev/null +++ b/problems/revising-strings/solution_it.md @@ -0,0 +1,11 @@ +--- + +# SÌ, LA PIZZA _È_ MERAVIGLIOSA. + +Ben fatto con quel metodo `.replace()`! + +Prossimamente esploreremo i **numeri**. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/revising-strings/solution_nb-no.md b/problems/revising-strings/solution_nb-no.md new file mode 100644 index 00000000..3211ea68 --- /dev/null +++ b/problems/revising-strings/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# JA, PIZZA _ER_ HERLIG! + +Bra jobbet med å bruke `.replace()` metoden! + +I neste oppgave skal vi utforske **tall**. + +Kjør `javascripting` for å velge neste oppgave + +--- diff --git a/problems/revising-strings/solution_nl.md b/problems/revising-strings/solution_nl.md new file mode 100644 index 00000000..1e79c1cc --- /dev/null +++ b/problems/revising-strings/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# YES, PIZZA _IS_ HEERLIJK. + +Knap gedaan met die `.replace()` method! + +Nu gaan we verder met **numbers**. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/revising-strings/solution_pt-br.md b/problems/revising-strings/solution_pt-br.md new file mode 100644 index 00000000..f4c46ce9 --- /dev/null +++ b/problems/revising-strings/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# SIM, PIZZA _É_ MARAVILHOSA. + +Muito bem feito! Você acertou com o método `.replace()`! + +Em seguida vamos explorar os **numbers**. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/revising-strings/solution_ru.md b/problems/revising-strings/solution_ru.md new file mode 100644 index 00000000..625ffc2f --- /dev/null +++ b/problems/revising-strings/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# О ДА, ПИЦЦА _ТЕПЕРЬ_ ВЕЛИКОЛЕПНА. + +Отлично, вы справились с методом `.replace()`! + +Дальше мы познакомимся с **числами**. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/revising-strings/solution_uk.md b/problems/revising-strings/solution_uk.md new file mode 100644 index 00000000..d813f27f --- /dev/null +++ b/problems/revising-strings/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ТАК, ПІЦА _ЧУДОВА_. + +Прекрасно впорались з методом `.replace()`! + +Далі ми дослідимо **числа**. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/revising-strings/solution_zh-tw.md b/problems/revising-strings/solution_zh-tw.md new file mode 100644 index 00000000..29819e02 --- /dev/null +++ b/problems/revising-strings/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 是的, PIZZA _IS_ WONDERFUL。 + +幹得漂亮,你已經學會了如何使用 `.replace()` 方法! + +接下來我們將探索 **numbers**,也就是**數字**。 + +運行 `javascripting` 命令並選擇下一個挑戰。 + +--- diff --git a/problems/rounding-numbers/index.js b/problems/rounding-numbers/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/rounding-numbers/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/rounding-numbers/problem.md b/problems/rounding-numbers/problem.md index 045b3106..dab7a39c 100644 --- a/problems/rounding-numbers/problem.md +++ b/problems/rounding-numbers/problem.md @@ -1,7 +1,3 @@ ---- - -# ROUNDING NUMBERS - We can do basic math using familiar operators like `+`, `-`, `*`, `/`, and `%`. For more complex math, we can use the `Math` object. @@ -14,12 +10,12 @@ Create a file named `rounding-numbers.js`. In that file define a variable named `roundUp` that references the float `1.5`. -We will use the `Math.round()` method to round the number up. +We will use the `Math.round()` method to round the number up. This method rounds either up or down to the nearest integer. An example of using `Math.round()`: ```js -Math.round(0.5); +Math.round(0.5) ``` Define a second variable named `rounded` that references the output of the `Math.round()` method, passing in the `roundUp` variable as the argument. @@ -28,6 +24,6 @@ Use `console.log()` to print that number to the terminal. Check to see if your program is correct by running this command: -`javascripting verify rounding-numbers.js` - ---- +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_es.md b/problems/rounding-numbers/problem_es.md index 07a810ee..cb36f15c 100644 --- a/problems/rounding-numbers/problem_es.md +++ b/problems/rounding-numbers/problem_es.md @@ -1,12 +1,8 @@ ---- - -# REDONDEANDO NÚMEROS - Los operadores básicos son `+`, `-`, `*`, `/`, y `%`. Para operaciones más complejas, podemos usar el objeto `Math`. -En este ejercicio utilizaremos el objeto `Math` para redondear números. +En este ejercicio utilizaremos el objeto `Math` para redondear números. ## El ejercicio: @@ -19,7 +15,7 @@ Usaremos el método `Math.round()` para redondear el número. Un ejemplo de `Math.round()`: ```js -Math.round(0.5); +Math.round(0.5) ``` Define una segunda variable llamada `rounded` que referencie lo que retorna el método `Math.round()`, pasando la variable `roundUp` cómo argumento. @@ -28,6 +24,6 @@ Utiliza `console.log()` para imprimir el número a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente commando: -`javascripting verify rounding-numbers.js` - ---- +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_fr.md b/problems/rounding-numbers/problem_fr.md new file mode 100644 index 00000000..5a87750d --- /dev/null +++ b/problems/rounding-numbers/problem_fr.md @@ -0,0 +1,29 @@ +Nous pouvons faire des mathématiques basiques avec les operateurs tels que `+`, `-`, `*`, `/`, et `%`. + +Pour des maths plus complexes, nous pouvons utiliser l'objet `Math`. + +Dans ce défi, nous allons utiliser l'objet `Math` pour arrondir des nombres. + +## Le défi : + +Créer un fichier nommé `nombres-arrondis.js`. + +Dans ce fichier, définissez une variable nommée `roundUp` qui contient le flottant `1.5`. + +Nous allons utiliser la méthode `Math.round()` pour arrondir notre nombre. Cette méthode retourne l'arrondi entier le plus proche. + +Un exemple d'utilisation de `Math.round()` : + +```js +Math.round(0.5) +``` + +Définissez une seconde variable nommée `rounded` qui contient le résultat de la méthode `Math.round()`, en lui passant la variable `roundUp` en argument. + +Utilisez `console.log()` pour afficher ce nombre dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify nombres-arrondis.js +``` diff --git a/problems/rounding-numbers/problem_it.md b/problems/rounding-numbers/problem_it.md new file mode 100644 index 00000000..e860cd23 --- /dev/null +++ b/problems/rounding-numbers/problem_it.md @@ -0,0 +1,29 @@ +Possiamo effettuare dei calcoli matematici di base usando operatori familiari come `+`, `-`, `*`, `/` e `%`. + +Per matematica più complessa, possiamo usare l'oggetto `Math`. + +In questa sfida useremo l'oggetto `Math` per arrotondare i numeri. + +## La sfida: + +Crea un file dal nome `rounding-numbers.js`. + +In questo file definisci una variabile chiamata `roundUp` che referenzia il valore decimale `1.5`. + +Useremo il metodo `Math.round()` per arrotondare il numero per eccesso. Questo metodo arrotonda sia per eccesso che per difetto all'intero più vicino. + +Un esempio dell'uso di `Math.round()`: + +```js +Math.round(0.5) +``` + +Definisci una seconda variabile chiamata `rounded` che referenzia l'output del metodo `Math.round()`, passando la variabile `roundUp` come argomento. + +Usa `console.log()` per stampare il numero ottenuto sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_ja.md b/problems/rounding-numbers/problem_ja.md index d8b22631..06e628cc 100644 --- a/problems/rounding-numbers/problem_ja.md +++ b/problems/rounding-numbers/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 数値丸め - 基本的な数値処理には、`+`、 `-`、 `*`、 `/`、 `%` といった、おなじみの演算子を使います。 より複雑な数値処理をするときは、 `Math` オブジェクトを使います。 @@ -15,12 +11,12 @@ rounding-numbers.jsファイルを作りましょう。 ファイルの中で、小数 `1.5` を表す、変数 `roundUp` を定義しましょう。 -`Math.round()` メソッドを使って数値を切り上げましょう。 +`Math.round()` メソッドを使って数値を切り上げましょう。 このメソッドは引数の数値を四捨五入して、最も近いの整数を返します。 `Math.round()` メソッドの使用例です... ```js -Math.round(0.5); +Math.round(0.5) ``` 第二の変数 `rounded` を定義します。この変数は `Math.round()` メソッドの結果を表します。引数には `roundUp` 変数を指定します。 @@ -29,6 +25,6 @@ Math.round(0.5); 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 -`javascripting verify rounding-numbers.js` - ---- +```bash +javascripting verify rounding-numbers.js +``` \ No newline at end of file diff --git a/problems/rounding-numbers/problem_ko.md b/problems/rounding-numbers/problem_ko.md index d37204c9..2ce04fdc 100644 --- a/problems/rounding-numbers/problem_ko.md +++ b/problems/rounding-numbers/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 숫자 반올림 - `+`, `-`, `*`, `/`, `%` 같은 익숙한 연산자를 사용해 기본적인 연산을 할 수 있습니다. 더 복잡한 연산은 `Math` 객체를 사용해 할 수 있습니다. @@ -14,12 +10,12 @@ 이 파일 안에서 실수 `1.5`를 참조하는 `roundUp`라는 변수를 선언합니다. -`Math.round()` 메소드를 이용해 숫자를 반올림합니다. +`Math.round()` 메소드를 이용해 숫자를 반올림합니다. 이 메소드는 숫자를 가까운 정수로 올리거나 내립니다. `Math.round()`을 사용하는 예입니다. ```js -Math.round(0.5); +Math.round(0.5) ``` `roundUp` 변수를 인자로 `Math.round()` 메소드에 넘긴 결과를 참조하는 `rounded`라는 두 번째 변수를 정의합니다. @@ -28,6 +24,6 @@ Math.round(0.5); 이 명령어를 실행해 프로그램이 올바른지 확인하세요. -`javascripting verify rounding-numbers.js` - ---- +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_nb-no.md b/problems/rounding-numbers/problem_nb-no.md new file mode 100644 index 00000000..420fc031 --- /dev/null +++ b/problems/rounding-numbers/problem_nb-no.md @@ -0,0 +1,30 @@ +Vi kan gjøre enkle regnestykker med operatører som `+`, `-`, `*`, `/`, og `%`. + +For mer avanserte regnestykker, kan vi bruke `Math` objektet. + +I denne oppgaven skal vi bruke `Math` objektet for å avrunde nummer. + +## Oppgaven: + +Lag en fil som heter `rounding-numbers.js`. + +Definer en variabel med navnet `roundUp` i den filen som referer flyttallet `1.5`. + +Vi vil bruke `Math.round()` metoden for å runde opp til nærmeste heltall. + +Et eksempel på bruk av `Math.round()`: + +```js +Math.round(0.5) +``` + +Definer en andre variabel med navnet `rounded` som referer resultat av `Math.round()` methoden, +gitt `roundUp` variabelen som argument. + +Bruk `console.log()` for å skrive det nummeret til skjermen. + +Se om programmet ditt er riktig ved å kjøre denne: + +```bash +javascripting verify rounding-numbers.js +``` \ No newline at end of file diff --git a/problems/rounding-numbers/problem_nl.md b/problems/rounding-numbers/problem_nl.md new file mode 100755 index 00000000..92b6488a --- /dev/null +++ b/problems/rounding-numbers/problem_nl.md @@ -0,0 +1,30 @@ +We kunnen simpele wiskundige bewerkingen doen met bekende operatoren zoals `+`, `-`, `*`, `/`, en `%`. + +Voor meer ingewikkelde wiskunde, gebruiken we het `Math` object. + +In deze uitdaging gebruiken we het `Math` object om nummers af te ronden. + +## De uitdaging: + +Maak een bestand met de naam `rounding-numbers.js`. + +Definieer in dit bestand een variabele met de naam `roundUp` die verwijst naar de float `1.5`. + +We gebruiken de `Math.round()` method om het getal naar boven af te ronden. +Deze method rond een getal met cijfers achter de komma naar boven of naar beneden af tot een geheel getal. + +Voorbeeld van hoe je `Math.round()` gebruikt: + +```js +Math.round(0.5) +``` + +Maak nu een tweede variabele met de naam `rounded` die verwijst naar de uitvoer van de `Math.round()` method, waar bij je de variabele `roundUp` geeft als argument. + +Gebruik `console.log()` om het resultaat naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_pt-br.md b/problems/rounding-numbers/problem_pt-br.md new file mode 100644 index 00000000..670c55f8 --- /dev/null +++ b/problems/rounding-numbers/problem_pt-br.md @@ -0,0 +1,29 @@ +Podemos fazer operações simples de matemática usando operadores como `+`, `-`, `*`, `/`, e `%`. + +Para cálculos complexos, usamos o objeto `Math`. + +Neste desafio usaremos o objeto `Math` para arredondar os números. + +## Desafio: + +Crie um arquivo chamado `rounding-numbers.js`. + +No arquivo que foi criado, defina uma veriável chamada `roundUp` que referencia o valor `1.5`. + +Usaremos o método `Math.round()` para arredondar o valor para cima. + +Veja um exemplo de utilização do método `Math.round()`: + +```js +Math.round(0.5) +``` + +Defina uma segunda variável chamada `rounded` que referencia a saída do método `Math.round()`, passando a variável `roundUp` como argumento. + +Use o `console.log()` para imprimir o número no terminal. + +Verifique se o seu programa está correto executando o comando: + +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_ru.md b/problems/rounding-numbers/problem_ru.md new file mode 100644 index 00000000..22262e75 --- /dev/null +++ b/problems/rounding-numbers/problem_ru.md @@ -0,0 +1,29 @@ +Мы можем производить вычисления, использую знакомые всем математические операторы, такие как `+`, `-`, `/` и `%`. + +Для более сложных вычислений мы можем воспользоваться объектом `Math`. + +В этой задаче мы будем использовать объект `Math` для округления чисел. + +## Условие задачи: + +Создайте файл под названием `rounding-numbers.js`. + +Объявите в нём переменную `roundUp` и задайте ей дробное значение `1.5`. + +Мы будем использовать метод `Math.round()` для округления этого числа. Этот метод округляет как в большую, так и в меньшую сторону, к ближайшему целому значению. + +Пример использования `Math.round()`: + +```js +Math.round(0.5) +``` + +Объявите вторую переменную `rounded`, которая ссылается на результат работы метода `Math.round()`, аргументом которой является переменная `roundUp`. + +Воспользуйтесь командой `console.log()`, чтобы вывести результат в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_uk.md b/problems/rounding-numbers/problem_uk.md new file mode 100644 index 00000000..84784d63 --- /dev/null +++ b/problems/rounding-numbers/problem_uk.md @@ -0,0 +1,29 @@ +Ми можемо виконувати прості математичні дії використовуючи звичайні оператори, як от `+`, `-`, `*`, `/`, та `%`. + +Для більш складних операцій ми можемо використовувати об’єкт `Math`. + +У цьому завданні ми використаємо об’єкт `Math` для округлення чисел. + +## Завдання: + +Створити файл `rounding-numbers.js`. + +У цьому файлі оголосити змінну `roundUp`, що міститиме дійсне число `1.5`. + +Для скруглення числа ми використаємо метод `Math.round()`. Цей метод округлює до найближчого до найближчого більшого, або меншого цілого числа. + +Приклад використання `Math.round()`: + +```js +Math.round(0.5) +``` + +Оголосіть ще одну змінну `rounded`, що посилатиметься на результат методу `Math.round()`, який прийматиме змінну `roundUp` в якості аргументу. + +Використайте `console.log()`, щоб вивести число до терміналу. + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_zh-cn.md b/problems/rounding-numbers/problem_zh-cn.md index 1ef7c09f..0b8b9915 100644 --- a/problems/rounding-numbers/problem_zh-cn.md +++ b/problems/rounding-numbers/problem_zh-cn.md @@ -1,7 +1,3 @@ ---- - -# 数字取整 - 我们可以对数字进行一些基本的数学运算,比如 `+`,`-`,`*`,`/`,和 `%`。 对于更复杂的数学运算,我们需要使用 `Math` 对象。 @@ -19,7 +15,7 @@ `Math.round()` 的例子: ```js -Math.round(0.5); +Math.round(0.5) ``` 再定义一个名为 `rounded` 的变量,让它引用 `Math.round()` 的结果。将 `roundUp` 作为参数传递。 @@ -28,6 +24,6 @@ Math.round(0.5); 运行下面的命令检查你的程序是否正确: -`javascripting verify rounding-numbers.js` - ---- +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/problem_zh-tw.md b/problems/rounding-numbers/problem_zh-tw.md new file mode 100644 index 00000000..7672ec7d --- /dev/null +++ b/problems/rounding-numbers/problem_zh-tw.md @@ -0,0 +1,29 @@ +我們可以對數字進行一些基本的數學運算,比如 `+`,`-`,`*`,`/`,和 `%`。 + +對於更複雜的數學運算,我們需要使用 `Math` 物件。 + +這個挑戰中我們將要使用 `Math` 物件來對數字進行取整。 + +## 挑戰: + +建立一個名為 `rounding-numbers.js` 的檔案。 + +在該檔案中定義一個名為 `roundUp` 的變數,並賦值浮點數 `1.5`。 + +下面就要使用 `Math.round()` 方法來對這個數進行向上取整。 + +`Math.round()` 的例子: + +```js +Math.round(0.5) +``` + +再定義一個名為 `rounded` 的變數,讓它引用 `Math.round()` 的結果。將 `roundUp` 作為參數傳遞。 + +使用 `console.log()` 印出結果到終端機上。 + +執行下面的命令檢查你寫的程式是否正確: + +```bash +javascripting verify rounding-numbers.js +``` diff --git a/problems/rounding-numbers/solution_fr.md b/problems/rounding-numbers/solution_fr.md new file mode 100644 index 00000000..4b390941 --- /dev/null +++ b/problems/rounding-numbers/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# CE NOMBRE EST ARRONDI + +Ouaip, vous venez d'arrondir le nombre `1.5` vers `2`. Bon boulot ! + +Dans le prochain défi, nous allons transformer un nombre en chaîne de caractères. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/rounding-numbers/solution_it.md b/problems/rounding-numbers/solution_it.md new file mode 100644 index 00000000..c296e57c --- /dev/null +++ b/problems/rounding-numbers/solution_it.md @@ -0,0 +1,11 @@ +--- + +# IL NUMERO È STATO ARROTONDATO + +Perfetto, hai appena arrotondato il numero `1.5` a `2`. Ottimo lavoro. + +Nella prossima sfida trasformeremo un numero in una stringa. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/rounding-numbers/solution_nb-no.md b/problems/rounding-numbers/solution_nb-no.md new file mode 100644 index 00000000..55d64be6 --- /dev/null +++ b/problems/rounding-numbers/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# NUMMERET ER AVRUNDET + +Jepp, du avrundet nummeret `1.5` til `2`. Bra jobba! + +I den neste oppgaven vil vi gjøre om et nummer til en string. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/rounding-numbers/solution_nl.md b/problems/rounding-numbers/solution_nl.md new file mode 100644 index 00000000..c7e8c979 --- /dev/null +++ b/problems/rounding-numbers/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# DAT GETAL IS AFGEROND + +Yep, je hebt net een getal afgerond van `1.5` naar `2`. Lekker bezig. + +In de volgende uitdaging gaan we een number in een string veranderen. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/rounding-numbers/solution_pt-br.md b/problems/rounding-numbers/solution_pt-br.md new file mode 100644 index 00000000..19c7c32e --- /dev/null +++ b/problems/rounding-numbers/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# AGORA TÁ REDONDO! + +Isso aê! Você arredondou o número `1.5` para `2`. Bom trabalho! + +No próximo desafio iremos transformar o número numa string. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/rounding-numbers/solution_ru.md b/problems/rounding-numbers/solution_ru.md new file mode 100644 index 00000000..1ac72323 --- /dev/null +++ b/problems/rounding-numbers/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ЧИСЛО ОКРУГЛЕНО + +Так точно, вы только что округлили число `1.5` до `2`. Хорошая работа! + +В следующей задаче мы будем превращать число в строку. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/rounding-numbers/solution_uk.md b/problems/rounding-numbers/solution_uk.md new file mode 100644 index 00000000..b9756de5 --- /dev/null +++ b/problems/rounding-numbers/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ЦІ ЧИСЛА СКРУГЛЕНІ + +Ага, ви просто округлили `1.5` до `2`. Круто. + +В наступному завданні ми перетворимо число в рядок. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/rounding-numbers/solution_zh-tw.md b/problems/rounding-numbers/solution_zh-tw.md new file mode 100644 index 00000000..8a626338 --- /dev/null +++ b/problems/rounding-numbers/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 很好,得到了取整的結果。 + +剛剛你已經把數 `1.5` 向上取整到了 `2`。 + +下一個挑戰裡我們將把一個數字轉變成一個字串。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/scope/index.js b/problems/scope/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/scope/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/scope/problem.md b/problems/scope/problem.md index b2e0387a..f6303e98 100644 --- a/problems/scope/problem.md +++ b/problems/scope/problem.md @@ -1,39 +1,38 @@ ---- - -# SCOPE - `Scope` is the set of variables, objects, and functions you have access to. JavaScript has two scopes: `global` and `local`. A variable that is declared outside a function definition is a `global` variable, and its value is accessible and modifiable throughout your program. A variable that is declared inside a function definition is `local`. It is created and destroyed every time the function is executed, and it cannot be accessed by any code outside the function. -Functions defined inside other functions, known as nested functions, have access to their parent function's scope. +Functions defined inside other functions, known as nested functions, have access to their parent function's scope. Pay attention to the comments in the code below: ```js -var a = 4; // a is a global variable, it can be accesed by the functions below - -function foo() { - var b = a * 3; // b cannot be accesed outside foo function, but can be accesed by functions - // defined inside foo - function bar(c) { - var b = 2; // another `b` variable is created inside bar function scope - // the changes to this new `b` variable don't affect the old `b` variable - console.log( a, b, c ); - } - - bar(b * 4); +const a = 4 // a is a global variable, it can be accessed by the functions below + +function foo () { + const b = a * 3 // b cannot be accessed outside foo function, but can be accessed by functions + // defined inside foo + function bar (c) { + const b = 2 // another `b` variable is created inside bar function scope + // the changes to this new `b` variable don't affect the old `b` variable + console.log(a, b, c) + } + + bar(b * 4) } -foo(); // 4, 2, 48 +foo() // 4, 2, 48 ``` -IIFE, Immediately Invoked Function Expression, is a common pattern for creating local scopes -example: + + +IIFE, Immediately Invoked Function Expression, is a common pattern for creating local scopes. + +Example: ```js - (function(){ // the function expression is surrounded by parenthesis - // variables defined here - // can't be accesed outside - })(); // the function is immediately invoked +(function () { // the function expression is surrounded by parentheses + // variables defined here + // can't be accessed outside +})() // the function is immediately invoked ``` ## The challenge: @@ -41,29 +40,33 @@ Create a file named `scope.js`. In that file, copy the following code: ```js -var a = 1, b = 2, c = 3; +const a = 1; const b = 2; const c = 3; -(function firstFunction(){ - var b = 5, c = 6; +(function firstFunction () { + const b = 5; const c = 6; - (function secondFunction(){ - var b = 8; - - (function thirdFunction(){ - var a = 7, c = 9; + (function secondFunction () { + const b = 8; - (function fourthFunction(){ - var a = 1, c = 8; + (function thirdFunction () { + const a = 7; const c = 9; - })(); - })(); - })(); -})(); + (function fourthFunction () { + const a = 1; const c = 8; + })() + })() + })() +})() ``` -Use your knowledge of the variables' `scope` and place the following code inside on of the functions in 'scope.js' -so the output is `a: 1, b: 8,c: 6` +Use your knowledge of the variables' `scope` and place the following code inside one of the functions in `scope.js` +so the output is `a: 1, b: 8, c: 6` ```js -console.log("a: "+a+", b: "+b+",c: "+c); +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Check to see if your program is correct by running this command: + +```bash +javascripting verify scope.js ``` ---- \ No newline at end of file diff --git a/problems/scope/problem_es.md b/problems/scope/problem_es.md index 51b6cb7c..a380f778 100644 --- a/problems/scope/problem_es.md +++ b/problems/scope/problem_es.md @@ -1,7 +1,3 @@ ---- - -# SCOPE ( AMBITO ) - El `scope` o ámbito es el conjunto de variables, objetos y funciones a las que tienes acceso. JavaScript tiene dos ámbitos: `global` y `local`. Una variable que es declarada fuera de la definición de una función es una variable `global`, y su valor es accesible y modificable a través de tu programa. Una variable que es declarada dentro de la definición de una función es una variable `local`. Se crea y se destruye cada vez que se ejecuta la función, y no se puede acceder a su valor ni modificarlo por ningún código fuera de la misma. @@ -11,29 +7,29 @@ Las funciones definidas dentro de otras funciones, conocidas como funciones anid Presta atención a los comentarios en el siguiente código: ```js -var a = 4; // es una variable global, puede ser accedida por las siguientes funciones - -function foo() { - var b = a * 3; // b no puede ser accedida por fuera de la función foo, pero puede ser accedida - // por las funciones definidas dentro de foo - function bar(c) { - var b = 2; // otra variable `b` es creada dentro del ámbito de la función bar - // los cambios a esta nueva `b` no afectan a la vieja variable `b` - console.log( a, b, c ); - } - - bar(b * 4); +const a = 4 // es una variable global, puede ser accedida por las siguientes funciones + +function foo () { + const b = a * 3 // b no puede ser accedida por fuera de la función foo, pero puede ser accedida + // por las funciones definidas dentro de foo + function bar (c) { + const b = 2 // otra variable `b` es creada dentro del ámbito de la función bar + // los cambios a esta nueva `b` no afectan a la vieja variable `b` + console.log(a, b, c) + } + + bar(b * 4) } -foo(); // 4, 2, 48 +foo() // 4, 2, 48 ``` -IIFE, Immediately Invoked Function Expression( Expresión de Functión Invocada Inmediatamente ), es un patrón común para crear ámbitos locales. +IIFE, Immediately Invoked Function Expression( Expresión de Función Invocada Inmediatamente ), es un patrón común para crear ámbitos locales. Por ejemplo: ```js - (function(){ // La expresión de la función está entre paréntesis - // las variables definidas aquí - // no pueden ser accedidas por fuera - })(); // la función es inmediatamente invocada +(function () { // La expresión de la función está entre paréntesis + // las variables definidas aquí + // no pueden ser accedidas por fuera +})() // la función es inmediatamente invocada ``` ## El ejercicio: @@ -41,29 +37,27 @@ Crea un archivo llamado `scope.js`. En ese archivo, copia el siguiente código: ```js -var a = 1, b = 2, c = 3; +const a = 1; const b = 2; const c = 3; -(function firstFunction(){ - var b = 5, c = 6; +(function firstFunction () { + const b = 5; const c = 6; - (function secondFunction(){ - var b = 8; - - (function thirdFunction(){ - var a = 7, c = 9; + (function secondFunction () { + const b = 8; - (function fourthFunction(){ - var a = 1, c = 8; + (function thirdFunction () { + const a = 7; const c = 9; - })(); - })(); - })(); -})(); + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() ``` Usa tu conocimiento sobre el ámbito de las variables y ubica el siguiente código dentro de alguna de las funciones -en `scope.js` para que la salida sea `a: 1, b: 8,c: 6` +en `scope.js` para que la salida sea `a: 1, b: 8, c: 6` ```js -console.log("a: "+a+", b: "+b+",c: "+c); +console.log(`a: ${a}, b: ${b}, c: ${c}`); ``` ---- \ No newline at end of file diff --git a/problems/scope/problem_fr.md b/problems/scope/problem_fr.md new file mode 100644 index 00000000..e6e0f298 --- /dev/null +++ b/problems/scope/problem_fr.md @@ -0,0 +1,71 @@ +Le `scope` est l'ensemble de variables, d'objets et de fonctions auxquels vous avez accès. + +Le JavaScript a deux scopes : le scope `global` et le scope `local`. Une variable qui est déclarée hors d'une fonction est une variable `globale` et sa valeur est accessible et modifiable à travers tout le programme. Une variable qui est déclarée dans une fonction est `locale`. Elle est créée et détruite à chaque fois que la fonction est exécutée, et n'est pas accessible en dehors de cette fonction. + +Les fonctions définies à l'intérieur d'autres fonctions, aussi connues en tant que fonctions imbriquées ( _nested_ ), ont accès au scope de leur fonction parent. + +Soyez attentif aux commentaires dans le code suivant : + +```js +const a = 4 // a est une variable globale, elle est accessible dans les fonctions ci-dessous + +function foo () { + const b = a * 3 // b n'est pas accessible hors de la fonction foo mais l'est + // dans les fonctions déclarées à l'intérieur de foo + + function bar (c) { + const b = 2 // une autre variable `b` est créée à l'intérieur du scope de la fonction + // les changements apportés à cette nouvelle variable `b` n'ont pas d'effet sur + // l'ancienne variable `b` + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` + +IIFE, Immediately Invoked Function Expression, est un schéma commun pour créer des scopes locaux : + +```js +(function () { // l'expression `function` est entourée par des parenthèses + // les variables définies ici + // ne sont pas accessibles en dehors +})() // la fonction est appelée immédiatement +``` +## Le défi : + +Créez un fichier nommé `scope.js`. + +Dans ce fichier, copiez le code suivant : +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +Utilisez vos connaissances des `scopes` de variables et placez le code suivant à l'intérieur d'une fonction de `scope.js` afin d'obtenir la sortie `a: 1, b: 8, c: 6` +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Vérifiez si votre programme est correct en exécutant la commande : + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_it.md b/problems/scope/problem_it.md new file mode 100644 index 00000000..17c8c103 --- /dev/null +++ b/problems/scope/problem_it.md @@ -0,0 +1,69 @@ +Lo `scope` o ambito è l'insieme di variabili, oggetti e funzioni a cui hai accesso. + +JavaScript possiede due ambiti: `globale` e `locale`. Una variabile dichiarata fuori da qualsiasi definizione di funzione è una variabile `globale`, e il suo valore è accessibile e modificabile all'interno dell'intero programma. Una variabile dichiarata dentro una definizione di funzione è `locale`. Viene creata e distrutta ogni volta che la funzione viene eseguita, e non può essere acceduta da codice esterno alla funzione. + +Le funzioni definite all'interno di altre funzioni, note come funzioni annidate, hanno accesso all'ambito della propria funzione genitrice. + +Presta attenzione ai commenti nel codice seguente: + +```js +const a = 4 // a è una variabile globale, può essere acceduta dalle funzioni seguenti + +function foo () { + const b = a * 3 // b non può essere acceduta fuori dalla funzione foo, ma può essere acceduta dalle funzioni + // definite all'interno di foo + function bar (c) { + const b = 2 // un'altra variabile `b` è creata all'interno dell'ambito della funzione bar + // i cambiamenti a questa nuova variabile `b` non hanno effetto sulla variabile `b` precedente + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` +IIFE, _Immediately Invoked Function Expression_ ovvero espressione di funzione invocata immediatamente, è un pattern comune per creare ambiti locali +esempio: +```js +(function () { // l'espressione di funzione è circondata da parentesi + // le variabili definite qui + // non possono essere accedute dall'esterno +})() // la funzione è invocata immediatamente +``` +## La sfida: + +Crea un file dal nome `scope.js`. + +In questo file, copia il codice seguente: +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +Usa la tua comprensione dell'`ambito` delle variabili e posiziona il codice seguente dentro una delle funzioni in `scope.js` +in maniera tale che il risultato sia `a: 1, b: 8,c: 6` +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_ja.md b/problems/scope/problem_ja.md index f649e27a..d3523c53 100644 --- a/problems/scope/problem_ja.md +++ b/problems/scope/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# スコープ - 「スコープ」は参照できる変数・オブジェクト・関数の集合です。 JavaScriptには、二つのスコープがあります。グローバルとローカルです。 @@ -14,31 +10,31 @@ JavaScriptには、二つのスコープがあります。グローバルとロ 次のソースコードのコメントを読んでください... ```js -var a = 4; // a はグローバル変数です。下の全ての関数から参照できます。 +const a = 4 // a はグローバル変数です。下の全ての関数から参照できます。 -function foo() { - var b = a * 3; // b は foo 関数の外からは参照できません。 foo 関数の中で定義した関数 bar からは参照できます。 +function foo () { + const b = a * 3 // b は foo 関数の外からは参照できません。 foo 関数の中で定義した関数 bar からは参照できます。 - function bar(c) { - var b = 2; // bar 関数の中でもう一つ b 変数を定義します - // 新しい b を変更しても、元の b 変数は変わりません。 - console.log( a, b, c ); - } + function bar (c) { + const b = 2 // bar 関数の中でもう一つ b 変数を定義します + // 新しい b を変更しても、元の b 変数は変わりません。 + console.log(a, b, c) + } - bar(b * 4); + bar(b * 4) } -foo(); // 4, 2, 48 +foo() // 4, 2, 48 ``` 即時実行関数式 (Immediately Invoked Function Expression : IIFE) という共通パターンで、ローカルスコープを作れます。 例えば... ```js -(function(){ // 関数式をカッコで括ります - // 変数はここで定義します - // 関数の外からは参照できません -})(); // 関数を即座に実行します +(function () { // 関数式をカッコで括ります + // 変数はここで定義します + // 関数の外からは参照できません +})() // 関数を即座に実行します ``` ## やってみよう @@ -47,30 +43,28 @@ foo(); // 4, 2, 48 ファイルの中に、次のソースコードをコピーしましょう... ```js -var a = 1, b = 2, c = 3; - -(function firstFunction(){ - var b = 5, c = 6; +const a = 1; const b = 2; const c = 3; - (function secondFunction(){ - var b = 8; +(function firstFunction () { + const b = 5; const c = 6; - (function thirdFunction(){ - var a = 7, c = 9; + (function secondFunction () { + const b = 8; - (function fourthFunction(){ - var a = 1, c = 8; + (function thirdFunction () { + const a = 7; const c = 9; - })(); - })(); - })(); -})(); + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() ``` 変数のスコープを活用しましょう。次のコードを関数の中に配置してください。`scope.js` の中の関数です。 そして、目指す出力は `a: 1, b: 8,c: 6` です。 ```js -console.log("a: "+a+", b: "+b+",c: "+c); +console.log(`a: ${a}, b: ${b}, c: ${c}`); ``` ---- diff --git a/problems/scope/problem_ko.md b/problems/scope/problem_ko.md index 79d58980..a53e2bdc 100644 --- a/problems/scope/problem_ko.md +++ b/problems/scope/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 스코프 - `스코프`는 접근할 수 있는 변수, 객체, 함수의 집합입니다. @@ -12,29 +8,29 @@ JavaScript에는 `전역`과 `지역` 두 개의 스코프가 있습니다. 함 아래 코드의 주석을 잘 읽어보세요. ```js -var a = 4; // 전연 변수 아래에 있는 함수에서 접근 가능 - -function foo() { - var b = a * 3; // b는 foo 함수 밖에서 접근할 수 없지만, foo 함수 안에서 - // 선언된 함수에서는 접근 가능 - function bar(c) { - var b = 2; // bar 함수 스코프 안에서 생성한 다른 `b` 변수 - // 새로 만든 `b` 변수를 변경해도 오래된 `b` 변수에는 영향이 없음 - console.log( a, b, c ); - } - - bar(b * 4); +const a = 4 // 전연 변수 아래에 있는 함수에서 접근 가능 + +function foo () { + const b = a * 3 // b는 foo 함수 밖에서 접근할 수 없지만, foo 함수 안에서 + + function bar (c) { + const b = 2 // bar 함수 스코프 안에서 생성한 다른 `b` 변수 + // 새로 만든 `b` 변수를 변경해도 오래된 `b` 변수에는 영향이 없음 + console.log(a, b, c) + } + + bar(b * 4) } -foo(); // 4, 2, 48 +foo() // 4, 2, 48 ``` 즉시 실행하는 함수식(IIFE, Immediately Invoked Function Expression)은 지역 스코프를 만드는 일반적인 패턴입니다. 예제: ```js - (function(){ // 함수식은 괄호로 둘러 쌈 - // 변수 선언은 여기서 - // 밖에서 접근할 수 없음 - })(); // 함수는 즉시 실행됨 +(function () { // 함수식은 괄호로 둘러 쌈 + // 변수 선언은 여기서 + // 밖에서 접근할 수 없음 +})() // 함수는 즉시 실행됨 ``` ## 도전 과제: @@ -42,28 +38,32 @@ foo(); // 4, 2, 48 이 파일에 다음 코드를 복사합니다. ```js -var a = 1, b = 2, c = 3; +const a = 1; const b = 2; const c = 3; -(function firstFunction(){ - var b = 5, c = 6; +(function firstFunction () { + const b = 5; const c = 6; - (function secondFunction(){ - var b = 8; - - (function thirdFunction(){ - var a = 7, c = 9; + (function secondFunction () { + const b = 8; - (function fourthFunction(){ - var a = 1, c = 8; + (function thirdFunction () { + const a = 7; const c = 9; - })(); - })(); - })(); -})(); + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() ``` -변수의 `스코프`에 관한 지식을 활용해 다음 코드를 'scope.js' 안의 함수 안에 넣어 `a: 1, b: 8,c: 6`를 출력하게 하세요. +변수의 `스코프`에 관한 지식을 활용해 다음 코드를 `scope.js` 안의 함수 안에 넣어 `a: 1, b: 8,c: 6`를 출력하게 하세요. ```js -console.log("a: "+a+", b: "+b+",c: "+c); +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +이 명령어를 실행해 프로그램이 올바른지 확인하세요. + +```bash +javascripting verify scope.js ``` ---- diff --git a/problems/scope/problem_nb-no.md b/problems/scope/problem_nb-no.md new file mode 100644 index 00000000..c7bf2645 --- /dev/null +++ b/problems/scope/problem_nb-no.md @@ -0,0 +1,68 @@ +`Scope` er de variablene, objektene og funksjonene du har tilgang til. + +JavaScript har to scope: `global` og `lokal`. En variabel som er deklarert utenfor en funksjon er en `global` variabel. Dens verdi er tilgjengelig og kan endres gjennom hele programmet ditt. En variabel som er deklarert inni en funksjon er `lokal`. Den lages og fjernes hver gang funksjonen kjøres og variabelen kan ikke nås av kode som er utenfor funksjonen. + +Funksjoner som er definert inni andre funksjoner, kjent som nøstede funksjoner, har tilgang til scopet til den ytre funksjonen den er deklarert i. + +Følg nøye med på kommentarene i koden under: + +```js +const a = 4 // a er en global variabel, den kan nås av funksjonene under + +function foo () { + const b = a * 3 // b kan ikke nås utenfor foo funksjonen, men kan nås av funksjoner + // definert inni foo + function bar (c) { + const b = 2 // enda en `b` variabel blir lagd i bar funksjonens scope + // endringer på den nye `b` variabelen endrer ikke den ytre `b` variabelen + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` +IIFE, Immediately Invoked Function Expression, er et pattern for å lage lokale scope +eksempel: +```js +(function () { // funksjonsuttrykket omgis av paranteser + // variabler defineres her + // kan ikke nås utenfor denne funksjonen +})() // funksjonen kjøres med engang +``` +## Oppgaven: + +Lag en fil som heter `scope.js`. + +Kopier inn følgende kode i den filen: +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +Bruk din kunnskap om variablenes `scope` og sett inn følgende kode i en av funksjonene som finnes i 'scope.js' slik at det skrives ut `a: 1, b: 8, c: 6` på skjermen: +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Se om programmet ditt er riktig ved å kjøre kommandoen: + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_nl.md b/problems/scope/problem_nl.md new file mode 100755 index 00000000..5c82e602 --- /dev/null +++ b/problems/scope/problem_nl.md @@ -0,0 +1,71 @@ +`Scope` noem je de variabele, objecten en functions waar je toegang toe hebt. + +JavaScript kent twee scopes: `global` en `local`. Een variabele die is gedeclareerd buiten een function definitie is een `globale` variabele, en die variabele is toegankelijk en aanpasbaar in alle programma code. Een variabele die is gedefinieerd binnen een function is `local`. De variabele wordt elke keer aangemaakt en weer verwijderd als de function wordt uitgevoerd, en kan niet worden benaderd door code buiten de function. + +Functions die worden gedefinieerd binnen andere functions, we noemen dat nested functions, hebben toegang tot de scope van de bovenliggende function. + +Let goed op de opmerkingen in de onderstaande code: + +```js +const a = 4 // a is een globale variabele, deze is toegankelijk via de onderstaande functions: + +function foo () { + const b = a * 3 // b is niet toegankelijk buiten de foo-function, maar is toegankelijk via functions + // die gedefinieerd zijn binnen foo + function bar (c) { + const b = 2 // een andere `b` variable is gedefinieerd in de bar function scope + // de veranderingen aan deze nieuwe `b` variabele hebben geen effect op de andere `b` variabele + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` + + +IIFE, Immediately Invoked Function Expression, is een veelgebruikte manier om een local scope te maken. + +Voorbeeld +```js +(function () { // de function (zonder naam) bevindt zich binnen haakjes. + // variabelen die hier worden gedefinieerd + // kunnen niet worden benaderd van buiten de function +})() // de function wordt direct aangeroepen / uitgevoerd +``` +## De uitdaging: + +Maak een nieuw bestand met de naam `scope.js`. + +Kopieer onderstaande code in je nieuwe bestand: +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8; + })() + })() + })() +})() +``` + +Gebruik je nieuwe kennis over de `scope` van variabelen en zet onderstaande code binnen één van de functions in je `scope.js` zodat dit de uitvoer wordt: `a: 1, b: 8, c: 6` +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Controleer of je programma goed werkt met dit commando: + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_pt-br.md b/problems/scope/problem_pt-br.md new file mode 100644 index 00000000..75719812 --- /dev/null +++ b/problems/scope/problem_pt-br.md @@ -0,0 +1,70 @@ +`Escopo` é o conjunto de variáveis, objetos, e funções dos quais temos acesso. + +O JavaScript tem dois escopos: `global` e `local`. Uma variável que é declarada fora da definição de uma função é uma variável `global`, e o seu valor pode ser acessado e modificado á partir de qualquer parte do seu programa. Uma variável que é declarada dentro da definição de uma função é `local`. Ela é criada e destruída toda vez que a função é executada, e não pode ser acessada por qualquer código fora da função. + +Funções definidas dentro de outras funções, conhecidas como funções aninhadas, tem acesso ao escopo da função pai. + +Preste atenção nos comentários do código abaixo: + +```js +const a = 4 // uma variável global, pode ser acessada pelas funções abaixo + +function foo () { + const b = a * 3 // b não pode ser acessada fora da função, mas pode ser acessada pelas funções + // definidas dentro da função foo + function bar (c) { + const b = 2 // uma outra variável `b` é criada dentro do escopo da função bar + // as mudanças dessa nova variável `b` não afeta a outra variável `b` + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` +IIFE, Immediately Invoked Function Expression (Expressão de Função Executada Imediatamente em tradução livre), é um padrão bastante usado para criar escopos locais. + +Exemplo: +```js +(function () { // a expressão da função é cercada por parênteses + // as variáveis definidas aqui + // não podem ser acessadas do lado de fora +})() // a função é executada imediatamente +``` +## Desafio: + +Crie um arquivo chamado `scope.js`. + +Nesse arquivo, copie o seguinte código: +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +Utilize seus conhecimentos sobre `escopo` de variáveis e posicione o seguinte código dentro de uma das funções no 'scope.js' +fazendo o resultado ser `a: 1, b: 8,c: 6` +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Verifique se o seu programa está correto executando o comando: + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_ru.md b/problems/scope/problem_ru.md new file mode 100644 index 00000000..32c3f4c9 --- /dev/null +++ b/problems/scope/problem_ru.md @@ -0,0 +1,75 @@ +`Область видимости` описывает множество переменных, объектов, а также функций, к которым есть непосредственный доступ. + +JavaScript обладает двумя областями видимости: `глобальной` и `локальной`. Переменная, объявленная снаружи функции, является `глобальной` переменной. Она доступна и изменяема из любого места вашей программы. При объявлении переменной внутри функции мы получаем `локальную` переменную. Она создаётся и удаляется каждый раз при вызове функции. К такой переменной нельзя получить доступ извне функции. + +Функции, объявленные внутри других функций, известные также как вложенные (дочерние) функции, имеют доступ к области видимости родительской функции. + +Обратите внимание на комментарии к приведённому ниже коду: + +```js +const a = 4 // это глобальная переменная, она доступна для функций ниже + +function foo () { + const b = a * 3 // к переменной `b` нет доступа снаружи функции `foo`, но к + // этой переменной имеют доступ функции, объявленные внутри `foo` + function bar (c) { + const b = 2 // ещё одна переменная `b` создана внутри области видимости + // функции `bar`, модификации этой новой переменной `b` никак не + // отразятся на объявленной выше переменной `b` + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` + +Непосредственно выполняемая функция-выражение (IIFE) -- распространённый паттерн создания локальной области видимости. + +Например: + +```js +(function () { // объявление функции окружено круглыми скобками + // переменные, объявленные здесь, + // не будут доступны снаружи +})() // функция сразу же вызывается +``` + +## Условия задачи + +Создайте файл `scope.js`. + +Скопируйте в него следующий код: + +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +Используя полученные знания об `областях видимости`, разместите приведённый ниже код внутри одной из функций, объявленных в `scope.js` так, чтобы на выходе получилось `a: 1, b: 8, c: 6`. + +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_uk.md b/problems/scope/problem_uk.md new file mode 100644 index 00000000..770553bf --- /dev/null +++ b/problems/scope/problem_uk.md @@ -0,0 +1,68 @@ +`Область видимості (Scope)` — це множина змінних, об’єктів та функцій до яких ви маєте доступ. + +JavaScript має дві області видимості: `глобальну` та `локальну`. Змінні, що оголошені поза визначенням функції є `глобальною` змінною, тож її значення буде доступне для читання та модифікації у всій вашій програмі. Змінну, яка оголошена всередині визначення функції, називають `локальною`. Вона створюється та знищується кожного разу коли функція виконується і її значення не можна отримати поза цієї функції. + +Функції, які визначені всередині інших функцій, також відомі як вкладені (nested) функції, мають доступ до області видимості їх батьківських функцій. + +Зверніть увагу на коментарі у цьому прикладі: + +```js +const a = 4 // a є глобальною змінною, її значення можна отримати з функцій нижче + +function foo () { + const b = a * 3 // b не можу бути доступною поза функцією foo, але доступна у + // функціях, оголошених всередині foo + function bar (c) { + const b = 2 // інша змінна `b` створена всередині функції bar зміна значення + // цієї змінної `b` не вплине на попередню змінну `b` + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` +Функції миттєвого (негайного) виклику, або «самовикликаючі» функцій (IIFE, Immediately Invoked Function Expression) є загальною практикою для створення локальних областей видимості +Приклад: +```js +(function () { // вираз функції оточений круглими дужками + // змінні оголошені тут + // не будуть доступними ззовні +})() // функція відразу ж викликається +``` +## Завдання: + +Створити файл `scope.js`. + +До цього файлу скопіювати такий код: +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +Використайте ваші знання про `область видимості` змінних та помістіть код нижче в таку функцію зі 'scope.js', щоб результат був рядок `a: 1, b: 8,c: 6`: +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` + +Перевірте вашу відповідь запустивши команду: + +```bash +javascripting verify scope.js +``` diff --git a/problems/scope/problem_zh-cn.md b/problems/scope/problem_zh-cn.md index a12dd1a5..f8c2ab4f 100644 --- a/problems/scope/problem_zh-cn.md +++ b/problems/scope/problem_zh-cn.md @@ -1,7 +1,3 @@ ---- - -# 作用域 - `作用域` 就是你能访问到的变量、对象以及函数的集合。 JavaScript 有两种类型的作用域:`全局` 以及 `局部`。函数外声明的变量是一个 `全局` 变量,它的值可以在整个程序中被访问和修改。函数内声明的变量是 `局部` 的,它随着函数的调用而被创建,随着函数的结束而被销毁。它不能在函数外被访问。 @@ -11,29 +7,29 @@ JavaScript 有两种类型的作用域:`全局` 以及 `局部`。函数外声 注意下面的代码: ```js -var a = 4; // a is a global variable, it can be accesed by the functions below - -function foo() { - var b = a * 3; // b cannot be accesed outside foo function, but can be accesed by functions - // defined inside foo - function bar(c) { - var b = 2; // another `b` variable is created inside bar function scope - // the changes to this new `b` variable don't affect the old `b` variable - console.log( a, b, c ); - } - - bar(b * 4); +const a = 4 // a is a global variable, it can be accesed by the functions below + +function foo () { + const b = a * 3 // b cannot be accesed outside foo function, but can be accesed by functions + // defined inside foo + function bar (c) { + const b = 2 // another `b` variable is created inside bar function scope + // the changes to this new `b` variable don't affect the old `b` variable + console.log(a, b, c) + } + + bar(b * 4) } -foo(); // 4, 2, 48 +foo() // 4, 2, 48 ``` 立即函式(IIFE, Immediately Invoked Function Expression)是用来创建局部作用域的常用方法。 例子: ```js - (function(){ // the function expression is surrounded by parenthesis - // variables defined here - // can't be accesed outside - })(); // the function is immediately invoked +(function () { // the function expression is surrounded by parenthesis + // variables defined here + // can't be accesed outside +})() // the function is immediately invoked ``` ## 挑战: @@ -41,28 +37,26 @@ foo(); // 4, 2, 48 在文件中复制粘贴下面的代码: ```js -var a = 1, b = 2, c = 3; +const a = 1; const b = 2; const c = 3; -(function firstFunction(){ - var b = 5, c = 6; +(function firstFunction () { + const b = 5; const c = 6; - (function secondFunction(){ - var b = 8; - - (function thirdFunction(){ - var a = 7, c = 9; + (function secondFunction () { + const b = 8; - (function fourthFunction(){ - var a = 1, c = 8; + (function thirdFunction () { + const a = 7; const c = 9; - })(); - })(); - })(); -})(); + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() ``` 依你对 `作用域` 的理解,将下面这段代码插入上述代码里,使得代码的输出为 `a: 1, b: 8,c: 6`。 ```js -console.log("a: "+a+", b: "+b+",c: "+c); +console.log(`a: ${a}, b: ${b}, c: ${c}`); ``` ---- \ No newline at end of file diff --git a/problems/scope/problem_zh-tw.md b/problems/scope/problem_zh-tw.md new file mode 100644 index 00000000..d544fd62 --- /dev/null +++ b/problems/scope/problem_zh-tw.md @@ -0,0 +1,62 @@ +`作用域` 就是你能訪問到的變數、物件以及函式的集合。 + +JavaScript 有兩種類型的作用域:`全域` 以及 `區域`。函式外宣告的變數是一個 `全域` 變數,它的值可以在整個程式中被存取和修改。函式內宣告的變數是 `區域` 的,它隨著函式的呼叫而被建立,再隨著函式的結束而被銷毀。它不能在函式以外被存取。 + +在函式中定義的函式,也叫巢狀函式,可以存取到外層函式的作用域。 + +注意下面的程式碼: + +```js +const a = 4 // a 是一個全域變數,它可以被下面的函式存取 + +function foo () { + const b = a * 3 // b 不能夠在 foo 函式以外被存取,但是可以被定義於 foo 內部的其他函式存取 + + function bar (c) { + const b = 2 // 另一個新的 `b` 變數被建立在 bar 函式的作用域內 + // 對這個新的 `b` 變數的改變並不會影響到舊的 `b` 變數 + console.log(a, b, c) + } + + bar(b * 4) +} + +foo() // 4, 2, 48 +``` +立即函式(IIFE, Immediately Invoked Function Expression)是用來建立區域作用域的常用方法。 +範例: +```js +(function () { // 這個函式語法被一組小括號括起來 + // 在這裡定義的變數 + // 不能夠在這個函式外被存取 +})() // 這個函式立即被執行 +``` +## 挑戰: + +建立一個名為 `scope.js` 的檔案。 + +在該檔案中複製貼上以下的程式碼: +```js +const a = 1; const b = 2; const c = 3; + +(function firstFunction () { + const b = 5; const c = 6; + + (function secondFunction () { + const b = 8; + + (function thirdFunction () { + const a = 7; const c = 9; + + (function fourthFunction () { + const a = 1; const c = 8 + })() + })() + })() +})() +``` + +依你對 `作用域` 的理解,將下面這段程式碼插入上述程式碼裡,使得程式碼的輸出為 `a: 1, b: 8,c: 6`。 +```js +console.log(`a: ${a}, b: ${b}, c: ${c}`); +``` diff --git a/problems/scope/solution.md b/problems/scope/solution.md index 4a351bd7..a2db4379 100644 --- a/problems/scope/solution.md +++ b/problems/scope/solution.md @@ -4,6 +4,8 @@ You got it! The second function has the scope we were looking for. -Run javascripting in the console to choose the next challenge. +Now move on to a more challenging Javascript workshopper **Functional Javascript**: + +npm install -g functional-javascript-workshop --- diff --git a/problems/scope/solution_es.md b/problems/scope/solution_es.md index 62692356..c4416387 100644 --- a/problems/scope/solution_es.md +++ b/problems/scope/solution_es.md @@ -1,6 +1,6 @@ --- -#EXCELENTE! +# EXCELENTE! Lo hiciste! La segunda función tiene el ámbito que estabamos buscando. diff --git a/problems/scope/solution_fr.md b/problems/scope/solution_fr.md new file mode 100644 index 00000000..4a0d3eee --- /dev/null +++ b/problems/scope/solution_fr.md @@ -0,0 +1,9 @@ +--- + +# EXCELLENT ! + +C'est bon ! La seconde fonction possède le `scope` que nous recherchons. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/scope/solution_it.md b/problems/scope/solution_it.md new file mode 100644 index 00000000..b0fffd22 --- /dev/null +++ b/problems/scope/solution_it.md @@ -0,0 +1,9 @@ +--- + +#ECCELLENTE! + +Ce l'hai fatta! La seconda funzione possiede l'ambito che cercavamo. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/scope/solution_nb-no.md b/problems/scope/solution_nb-no.md new file mode 100644 index 00000000..903400cd --- /dev/null +++ b/problems/scope/solution_nb-no.md @@ -0,0 +1,9 @@ +--- + +# UTMERKET! + +Du skjønte det! Den andre funksjonen har det scopet vi lette etter. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/scope/solution_nl.md b/problems/scope/solution_nl.md new file mode 100644 index 00000000..b1fd79d4 --- /dev/null +++ b/problems/scope/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# EXCELLENT! + +Goed gedaan! De tweede function heeft de scope die we zochten. + +Ga nu verder met een meer uitdagende Javascript workshopper **Functional Javascript**: + +npm install -g functional-javascript-workshop + +--- diff --git a/problems/scope/solution_pt-br.md b/problems/scope/solution_pt-br.md new file mode 100644 index 00000000..92253b43 --- /dev/null +++ b/problems/scope/solution_pt-br.md @@ -0,0 +1,9 @@ +--- + +#EXCELENTE! + +Você pegou o jeito! A segunda função tem o escopo que procurávamos. + +Execute javascripting no console para escolher o próximo desafio. + +--- diff --git a/problems/scope/solution_ru.md b/problems/scope/solution_ru.md new file mode 100644 index 00000000..e8fdd9ae --- /dev/null +++ b/problems/scope/solution_ru.md @@ -0,0 +1,9 @@ +--- + +# НЕВЕРОЯТНО! + +У вас получилось! Именно вторая функция обладает нужной нам областью видимости. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/scope/solution_uk.md b/problems/scope/solution_uk.md new file mode 100644 index 00000000..8597bbf8 --- /dev/null +++ b/problems/scope/solution_uk.md @@ -0,0 +1,9 @@ +--- + +# ЧУДОВО! + +Ви зробили це! Друга функція має саме таку область видимості, яку ми шукали. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/scope/solution_zh-tw.md b/problems/scope/solution_zh-tw.md new file mode 100644 index 00000000..dfc80fc3 --- /dev/null +++ b/problems/scope/solution_zh-tw.md @@ -0,0 +1,9 @@ +--- + +# 真棒! + +第二個函式的作用域就是我們要找的。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/string-length/index.js b/problems/string-length/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/string-length/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/string-length/problem.md b/problems/string-length/problem.md index a00d101a..71e071c8 100644 --- a/problems/string-length/problem.md +++ b/problems/string-length/problem.md @@ -1,17 +1,13 @@ ---- - -# STRING LENGTH - You will often need to know how many characters are in a string. For this you will use the `.length` property. Here's an example: ```js -var example = 'example string'; +const example = 'example string' example.length ``` -#NOTE +## NOTE Make sure there is a period between `example` and `length`. @@ -31,5 +27,3 @@ Use `console.log` to print the **length** of the string to the terminal. **Check to see if your program is correct by running this command:** `javascripting verify string-length.js` - ---- diff --git a/problems/string-length/problem_es.md b/problems/string-length/problem_es.md index f280cce0..1bc9e517 100644 --- a/problems/string-length/problem_es.md +++ b/problems/string-length/problem_es.md @@ -1,17 +1,13 @@ ---- - -# LONGITUD DE STRINGS - Muy seguido necesitarás saber cuantos caracteres hay en una string. Para esto, usarás la propiedad `.length`. Por ejemplo: ```js -var example = 'example string'; +const example = 'example string' example.length ``` -#NOTA +## NOTA Asegúrate de que hay un punto entre `example` y `length` @@ -31,5 +27,3 @@ Utiliza `console.log` para imprimir el **length** de la string a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: `javascripting verify string-length.js` - ---- diff --git a/problems/string-length/problem_fr.md b/problems/string-length/problem_fr.md new file mode 100644 index 00000000..c78407e6 --- /dev/null +++ b/problems/string-length/problem_fr.md @@ -0,0 +1,29 @@ +Vous allez assez souvent avoir besoin de savoir combien de caractères sont contenus dans une chaîne de caractères. + +Pour cela vous allez utiliser la propriété `.length`. Voici un exemple : + +```js +const example = 'example string' +example.length +``` + +## NOTE + +Assurez vous qu'il y ait un point entre `example` et `length`. + +Le code ci-dessus renverra un **nombre** contenant le nombre total de caractères de la chaîne de caractères. + + +## Le défi : + +Créez un fichier nommé `longueur-chaine.js`. + +Dans ce fichier, créez une variable nommée `example`. + +**Assignez la chaîne de caractères `'example string'` à la variable `example`.** + +Utilisez `console.log` pour afficher la **longueur** de la chaîne de caractères dans le terminal. + +**Vérifiez si votre programme est correct en exécutant la commande :** + +`javascripting verify longueur-chaine.js` diff --git a/problems/string-length/problem_it.md b/problems/string-length/problem_it.md new file mode 100644 index 00000000..0bacfb2e --- /dev/null +++ b/problems/string-length/problem_it.md @@ -0,0 +1,29 @@ +Avrai spesso bisogno di conoscere quanti caratteri vi siano in una stringa. + +A questo scopo userai la proprietà `.length`. Ecco un esempio: + +```js +const example = 'example string' +example.length +``` + +## NOTA + +Assicurati che ci sia un punto tra `example` e `length`. + +Il codice precedente restituirà un **numero** che rappresenta il numero totale di caratteri nella stringa. + + +## La sfida: + +Crea un file dal nome `string-length.js`. + +In questo file, crea una variabile chiamata `example`. + +**Assegna la stringa `'example string'` alla variabile `example`.** + +Usa `console.log` per stampare la **lunghezza** della stringa sul terminale. + +**Verifica che il tuo programma sia corretto eseguendo questo comando:** + +`javascripting verify string-length.js` diff --git a/problems/string-length/problem_ja.md b/problems/string-length/problem_ja.md index 948029f8..531f07bc 100644 --- a/problems/string-length/problem_ja.md +++ b/problems/string-length/problem_ja.md @@ -1,13 +1,9 @@ ---- - -# 文字列の長さ - ある文字列の文字数を知りたいことがあります。 そういう時は `.length` プロパティを使います。たとえば... ```js -var example = 'example string'; +const example = 'example string' example.length ``` @@ -28,5 +24,3 @@ example.length 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 `javascripting verify string-length.js` - ---- diff --git a/problems/string-length/problem_ko.md b/problems/string-length/problem_ko.md index 3995af09..313abfa6 100644 --- a/problems/string-length/problem_ko.md +++ b/problems/string-length/problem_ko.md @@ -1,23 +1,18 @@ ---- - -# 문자열 길이 - 문자열에 얼마나 많은 문자가 있는지 알아야 할 때가 자주 있을 겁니다. 이는 `.length` 속성을 이용하면 알 수 있습니다. 다음 예제를 보세요. ```js -var example = 'example string'; +const example = 'example string' example.length ``` -# 주의 +## 주의 `example`과 `length` 사이에 마침표가 있는 것을 확인하세요. 위의 코드는 문자열 안에 있는 전체 문자의 **수**를 반환합니다. - ## 도전 과제 `string-length.js`라는 파일을 만듭니다. @@ -31,5 +26,3 @@ example.length **이 명령어를 실행해 프로그램이 올바른지 확인하세요.** `javascripting verify string-length.js` - ---- diff --git a/problems/string-length/problem_nb-no.md b/problems/string-length/problem_nb-no.md new file mode 100644 index 00000000..cd539fc3 --- /dev/null +++ b/problems/string-length/problem_nb-no.md @@ -0,0 +1,29 @@ +Du har ofte behov for å vite hvor mange tegn det er i en streng. + +For å finne ut det kan du bruke `.length` egenskapen. Slik som dette: + +```js +const example = 'eksempel streng' +example.length +``` + +## OBS + +Pass på at du har et punktum mellom `example` og `length`. + +Koden ovenfor vil returnere et **tall** som er totalt antall tegn for i denne strengen. + + +## Oppgaven: + +Lag en fil som heter `string-length.js`. + +I filen skal du lage en variabel med navn `example`. + +**Tildel strengen `'example string'` til variabelen `example`.** + +Til å skrive ut lengden på strengen til skjermen kan du bruke `console.log`. + +**Se om programmet ditt er riktig ved å kjøre denne:** + +`javascripting verify string-length.js` diff --git a/problems/string-length/problem_nl.md b/problems/string-length/problem_nl.md new file mode 100755 index 00000000..25cfe354 --- /dev/null +++ b/problems/string-length/problem_nl.md @@ -0,0 +1,30 @@ + +Je moet vaak weten hoeveel tekens er in een string zitten. + +Daarvoor gebruik je de `.length` eigenschap. Hier is een voorbeeld: + +```js +const example = 'example string' +example.length +``` + +## LET OP + +Zorg ervoor dat er een punt staat tussen `example` en `length`. + +De code hierboven geeft een **number** met het totaal aantal karakters in de **string**. + + +## De uitdaging: + +Maak een bestand met de naam `string-length.js`. + +Maak in dat bestand een variabele met de naam `example`. + +**Wijs de string `'example string'` toe aan de variabele `example`.** + +Gebruik `console.log` om de **length** van de string naar de console te printen. + +**Controleer of je programma goed werkt met dit commando:** + +`javascripting verify string-length.js` diff --git a/problems/string-length/problem_pt-br.md b/problems/string-length/problem_pt-br.md new file mode 100644 index 00000000..d4fa8585 --- /dev/null +++ b/problems/string-length/problem_pt-br.md @@ -0,0 +1,29 @@ +Você irá frequentemente precisar saber quantos caracteres estão em uma string. + +Para isso você usará a propriedade `.length` da string. Aqui está um exemplo: + +```js +const example = 'example string' +example.length +``` + +## OBSERVAÇÕES + +Tenha certeza de que existe um ponto entre `example` e `length`. + +O código acima irá retornar um **number** com o total de caracteres na string. + + +## Desafio: + +Crie um arquivo chamado `string-length.js`. + +Nest arquivo, crie uma variável chamada `example`. + +**Referencie a `'example string'` á variável `example`.** + +Use o `console.log` para imprimir o **length** (tamanho) da string no terminal. + +**Verifique se o seu projeto está correto executando o comando:** + +`javascripting verify string-length.js` diff --git a/problems/string-length/problem_ru.md b/problems/string-length/problem_ru.md new file mode 100644 index 00000000..41bbe2c1 --- /dev/null +++ b/problems/string-length/problem_ru.md @@ -0,0 +1,31 @@ +Очень часто нужно узнать количество символов, содержащихся в заданной строке. + +Для этого мы будем использовать свойство `.length`. Например: + +```js +const example = 'example string' +example.length +``` + +## НА ЗАМЕТКУ + +Удостовертесь, что между `example` и `length` присутствует _точка_. + +Код выше должен вернуть **число** символов в заданной строке. + + +## Условие задачи: + +Создайте файл `string-length.js`. + +В этом файле объявите переменную `example`. + +**Присвойте переменной `example` строку `'example string'`.** + +Воспользуйтесь командой `console.log()`, чтобы вывести **длину** строки в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify string-length.js +``` diff --git a/problems/string-length/problem_uk.md b/problems/string-length/problem_uk.md new file mode 100644 index 00000000..e840404d --- /dev/null +++ b/problems/string-length/problem_uk.md @@ -0,0 +1,29 @@ +Часто вам мотрібно буде дізнатись довжину рядка. + +Для цього ви можете використати властивість `.length`. Ось приклад: + +```js +const example = 'example string' +example.length +``` + +## ЗАУВАЖЕННЯ + +Впевніться, що між `example` та `length` стоїть крапка. + +Код вище поверне **число (Number)**, яке становитиме кількість символів у рядку. + + +## Завдання: + +Створити файл `string-length.js`. + +У цьому файлі створити змінну `example`. + +**Присвоїти рядок `'example string'` змінній `example`.** + +Використайте `console.log`, щоб вивести **довжину** цього рядка до терміналу. + +**Перевірте вашу відповідь запустивши команду:** + +`javascripting verify string-length.js` diff --git a/problems/string-length/problem_zh-cn.md b/problems/string-length/problem_zh-cn.md index 9588a3b3..e5c9299c 100644 --- a/problems/string-length/problem_zh-cn.md +++ b/problems/string-length/problem_zh-cn.md @@ -1,17 +1,13 @@ ---- - -# 字符串长度 - 在程序中我们经常需要知道一个字符串中到底包含了多少字符。 你可以使用 `.length` 来得到它。下面是一个例子: ```js -var example = 'example string'; +const example = 'example string' example.length ``` -# 注 +## 注 不要忘记 `example` 和 `length` 之间的英文句号。 @@ -31,5 +27,3 @@ example.length **运行下面的命令来检查你的程序是否正确:** `javascripting verify string-length.js` - ---- diff --git a/problems/string-length/problem_zh-tw.md b/problems/string-length/problem_zh-tw.md new file mode 100644 index 00000000..906b4f59 --- /dev/null +++ b/problems/string-length/problem_zh-tw.md @@ -0,0 +1,29 @@ +在程式中我們經常需要知道一個字串中到底包含了多少字元。 + +你可以使用 `.length` 來得到它。下面是一個例子: + +```js +const example = 'example string' +example.length +``` + +## 注 + +不要忘記 `example` 和 `length` 之間的點(英文句號)。 + +上面這段程式碼將返回一個 **number**,也就是**數字**,指明字串中的字元個數。 + + +## 挑戰: + +建立一個名為 `string-length.js` 的檔案。 + +在該檔案中,建立一個名為 `example` 的變數。 + +**將字串 `'example string'` 賦給變數 `example`。** + +使用 `console.log` 印出這個字串的**length**,也就是**長度**到終端機上。 + +**執行下面的命令來檢查你寫的程式是否正確:** + +`javascripting verify string-length.js` diff --git a/problems/string-length/solution_es.md b/problems/string-length/solution_es.md index 42372bb4..2f5eee43 100644 --- a/problems/string-length/solution_es.md +++ b/problems/string-length/solution_es.md @@ -1,8 +1,8 @@ --- -# WIN: 17 CARACTERES +# WIN: 14 CARACTERES -Lo hiciste! La string `una string de ejemplo` tiene 17 caracteres. +Lo hiciste! La string `example string` tiene 14 caracteres. Ejecuta `javascripting` en la consola para seleccionar el siguiente ejercicio. diff --git a/problems/string-length/solution_fr.md b/problems/string-length/solution_fr.md new file mode 100644 index 00000000..02b4ebef --- /dev/null +++ b/problems/string-length/solution_fr.md @@ -0,0 +1,9 @@ +--- + +# GAGNE: 14 CARACTERES + +Vous l'avez fait ! La chaîne de caractères `example string` contient 14 caractères. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/string-length/solution_it.md b/problems/string-length/solution_it.md new file mode 100644 index 00000000..da32f717 --- /dev/null +++ b/problems/string-length/solution_it.md @@ -0,0 +1,9 @@ +--- + +# VITTORIA: 14 CARATTERI + +Ce l'hai fatta! La stringa `example string` contiene 14 caratteri. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/string-length/solution_nb-no.md b/problems/string-length/solution_nb-no.md new file mode 100644 index 00000000..075fe53c --- /dev/null +++ b/problems/string-length/solution_nb-no.md @@ -0,0 +1,9 @@ +--- + +# RIKTIG: 14 TEGN + +Jippi, du fikk det til! Strengen `example string` har 14 tegn. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/string-length/solution_nl.md b/problems/string-length/solution_nl.md new file mode 100644 index 00000000..61ad9293 --- /dev/null +++ b/problems/string-length/solution_nl.md @@ -0,0 +1,9 @@ +--- + +# WIN: 14 CHARACTERS + +Inderdaad! De string `example string` heeft 14 characters. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/string-length/solution_pt-br.md b/problems/string-length/solution_pt-br.md new file mode 100644 index 00000000..2b27f4e4 --- /dev/null +++ b/problems/string-length/solution_pt-br.md @@ -0,0 +1,9 @@ +--- + +# VITÓRIA! + +Você conseguiu! A string `example string` tem 14 caracteres. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/string-length/solution_ru.md b/problems/string-length/solution_ru.md new file mode 100644 index 00000000..2b322b38 --- /dev/null +++ b/problems/string-length/solution_ru.md @@ -0,0 +1,9 @@ +--- + +# ПОБЕДА: 14 СИМВОЛОВ + +У вас получилось! В строке `example string` 14 символов. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/string-length/solution_uk.md b/problems/string-length/solution_uk.md new file mode 100644 index 00000000..163adef5 --- /dev/null +++ b/problems/string-length/solution_uk.md @@ -0,0 +1,9 @@ +--- + +# ЦЕ ПЕРЕМОГА: 14 СИМВОЛІВ + +Вам вдалось! Рядок `example string` містить 14 символів. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/string-length/solution_zh-tw.md b/problems/string-length/solution_zh-tw.md new file mode 100644 index 00000000..69622a89 --- /dev/null +++ b/problems/string-length/solution_zh-tw.md @@ -0,0 +1,9 @@ +--- + +# 正確:14 個字元 + +你得到了正確的答案。字串 `example string` 含有 14 個字元。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/strings/index.js b/problems/strings/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/strings/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/strings/problem.md b/problems/strings/problem.md index 3533b04b..0853de18 100644 --- a/problems/strings/problem.md +++ b/problems/strings/problem.md @@ -1,19 +1,18 @@ ---- +A **string** is a sequence of characters. A ***character*** is, roughly +speaking, a written symbol. Examples of characters are letters, numbers, +punctuation marks, and spaces. -# STRINGS - -A **string** is any value surrounded by quotes. - -It can be single or double quotes: +String values are surrounded by either single or double quotation marks. ```js 'this is a string' "this is also a string" ``` -#NOTE -Try to stay consistent. In this workshop we'll only use single quotes. +## NOTE + +Try to stay consistent. In this workshop we'll only use single quotation marks. ## The challenge: @@ -22,7 +21,7 @@ For this challenge, create a file named `strings.js`. In that file create a variable named `someString` like this: ```js -var someString = 'this is a string'; +const someString = 'this is a string' ``` Use `console.log` to print the variable **someString** to the terminal. @@ -30,5 +29,3 @@ Use `console.log` to print the variable **someString** to the terminal. Check to see if your program is correct by running this command: `javascripting verify strings.js` - ---- diff --git a/problems/strings/problem_es.md b/problems/strings/problem_es.md index e1b5d79e..e28af53e 100644 --- a/problems/strings/problem_es.md +++ b/problems/strings/problem_es.md @@ -1,7 +1,3 @@ ---- - -# STRINGS - Una **string** representa una cadena de caracteres y se puede definir con comillas dobles o simples. Por ejemplo: @@ -11,7 +7,8 @@ Por ejemplo: "this is also a string" ``` -#NOTA + +## NOTA Trata de permanecer consistente. En este workshop usaremos comillas simples. @@ -22,7 +19,7 @@ Para este ejercicio, crea un archivo llamado `strings.js`. En ese archivo define una variable llamada `someString` de la siguiente forma: ```js -var someString = 'this is a string'; +const someString = 'this is a string' ``` Utiliza `console.log` para imprimir la variable `someString` a la terminal. @@ -30,5 +27,3 @@ Utiliza `console.log` para imprimir la variable `someString` a la terminal. Comprueba si tu programa es correcto ejecutando el siguiente comando: `javascripting verify strings.js` - ---- diff --git a/problems/strings/problem_fr.md b/problems/strings/problem_fr.md new file mode 100644 index 00000000..4ba81bbc --- /dev/null +++ b/problems/strings/problem_fr.md @@ -0,0 +1,29 @@ +Une **chaine de caractères** peut être n'importe quelle valeur entourée par des guillemets. + +Il peut s'agir de guillemets simples ou doubles : + +```js +'this is a string' + +"this is also a string" +``` + +## NOTE + +Essayez de rester cohérent. Dans ce TP, nous n'allons utiliser que des guillemets simples. + +## Le défi : + +Pour ce défi, créez un fichier nommé `chaines.js`. + +Dans ce fichier, créez une variable nommée `someString` comme cela : + +```js +const someString = 'this is a string' +``` + +Utilisez `console.log` pour afficher la variable **someString** dans le terminal. + +Vérifiez si votre programme est correct en exécutant la commande : + +`javascripting verify chaines.js` diff --git a/problems/strings/problem_it.md b/problems/strings/problem_it.md new file mode 100644 index 00000000..85879457 --- /dev/null +++ b/problems/strings/problem_it.md @@ -0,0 +1,29 @@ +Una **stringa** è ciascun valore delimitato da apici. + +Sono ammessi sia apici singoli che doppi: + +```js +'questa è una stringa' + +"anche questa è una stringa" +``` + +## NOTA + +Prova a rimanere consistente. In questo workshop useremo soltanto apici singoli. + +## La sfida: + +Per risolvere questa sfida, crea un file dal nome `strings.js`. + +In questo file crea una variabile dal nome `someString` come segue: + +```js +const someString = 'this is a string' +``` + +Usa `console.log` per stampare la variabile **someString** sul terminale. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +`javascripting verify strings.js` diff --git a/problems/strings/problem_ja.md b/problems/strings/problem_ja.md index d6ef268d..7ca378de 100644 --- a/problems/strings/problem_ja.md +++ b/problems/strings/problem_ja.md @@ -1,7 +1,3 @@ ---- - -# 文字列 - **文字列**は引用符でくくった値です。 引用符は一重引用符と二重引用符のどちらも使えます。例えば... @@ -12,6 +8,8 @@ "this is also a string" ``` +## 注意 + どちらかの引用符を使うルールを決め、守りましょう。 このワークショップでは一重引用符だけを使います。 ## やってみよう @@ -21,13 +19,11 @@ ファイルの中で、次のように変数 `someString` を作りましょう。 ```js -var someString = 'this is a string'; +const someString = 'this is a string' ``` -`console.log` を使い、変数 **someStirng** をターミナルに表示しましょう。 +`console.log` を使い、変数 **someString** をターミナルに表示しましょう。 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 `javascripting verify strings.js` - ---- diff --git a/problems/strings/problem_ko.md b/problems/strings/problem_ko.md index fc077c99..c506851d 100644 --- a/problems/strings/problem_ko.md +++ b/problems/strings/problem_ko.md @@ -1,7 +1,3 @@ ---- - -# 문자열 - **문자열**은 따옴표로 감싸진 값입니다. 이는 작은따옴표도 될 수 있고 큰따옴표도 될 수 있습니다. @@ -11,7 +7,8 @@ "this is also a string" ``` -# 주의 + +## 주의 일관성을 유지하도록 노력해보세요. 이 워크숍에서는 작은따옴표만 사용하도록 하겠습니다. @@ -22,7 +19,7 @@ 그 파일 안에서 `someString`이라는 변수를 만드세요. 이렇게 하면 됩니다. ```js -var someString = 'this is a string'; +const someString = 'this is a string' ``` `console.log`를 사용해 **someString** 변수를 터미널에 출력합니다. @@ -30,5 +27,3 @@ var someString = 'this is a string'; 이 명령어를 실행해 프로그램이 올바른지 확인하세요. `javascripting verify strings.js` - ---- diff --git a/problems/strings/problem_nb-no.md b/problems/strings/problem_nb-no.md new file mode 100644 index 00000000..a72f0380 --- /dev/null +++ b/problems/strings/problem_nb-no.md @@ -0,0 +1,27 @@ +En **string** er en verdi omgitt av anførselsteng eller apostrof: + +```js +'dette er en string' + +"dette er også en string" +``` + +## OBS + +Det lønner seg å være konsekvent på om du bruker anførselstegn eller apostrof. I denne oppgaven skal vi bare bruke apostrof. + +## Utfordringen: + +I denne oppgaven, lage en fil med navnet `strings.js`. + +Lage en variabel `someString`, slik som dette: + +```js +const someString = 'this is a string' +``` + +For å skrive variabelen **someString** til skjermen kan du bruke `console.log`. + +Se om programmet ditt er riktig ved å kjøre denne kommandoen: + +`javascripting verify strings.js` diff --git a/problems/strings/problem_nl.md b/problems/strings/problem_nl.md new file mode 100644 index 00000000..40964729 --- /dev/null +++ b/problems/strings/problem_nl.md @@ -0,0 +1,30 @@ +Een **string** is een reeks characters. Een ***character*** is, ruwweg gezegd +een geschreven symbool. Voorbeelden van characters zijn letters, cijfers, leestekens en spaties. + +Strings worden omgeven door enkele of dubbele aanhalingstekens. + +```js +'this is a string' + +"this is also a string" +``` + +## NOTE + +Probeer consistent te zijn. In deze workshop gebruiken we alleen enkele aanhalingstekens. + +## De uitdaging: + +Maak voor deze uitdaging een nieuw bestand met de naam `strings.js`. + +Definieer in dit bestand een nieuwe variabele `someString` zoals hieronder: + +```js +const someString = 'this is a string' +``` + +Gebruik `console.log` om de variabele **someString** naar de console te printen. + +Controleer of je programma goed werkt met dit commando: + +`javascripting verify strings.js` diff --git a/problems/strings/problem_pt-br.md b/problems/strings/problem_pt-br.md new file mode 100644 index 00000000..a7919a1a --- /dev/null +++ b/problems/strings/problem_pt-br.md @@ -0,0 +1,29 @@ +Uma **string** pode ser qualquer valor cercado de aspas. + +Pode ser usado aspas simples ou aspas duplas: + +```js +'this is a string' + +"this is also a string" +``` + +## OBSERVAÇÃO + +Tente ser consistente. Neste workshop usaremos apenas aspas simples. + +## Desafio: + +Para este desafio, crie um arquivo chamado `strings.js`. + +No arquivo que foi criado, crie uma variável chamada `someString` da seguinte forma: + +```js +const someString = 'this is a string' +``` + +Use o `console.log` para imprimir a variável **someString** para o terminal. + +Verifique se o seu programa está correto executando este comando: + +`javascripting verify strings.js` diff --git a/problems/strings/problem_ru.md b/problems/strings/problem_ru.md new file mode 100644 index 00000000..c00aca28 --- /dev/null +++ b/problems/strings/problem_ru.md @@ -0,0 +1,31 @@ +Любое значение, окруженное кавычками, является **строкой**. + +Для этого можно использовать как одинарные, так и двойные кавычки: + +```js +'this is a string' + +"this is also a string" +``` + +## НА ЗАМЕТКУ + +Старайтесь быть последовательны и используйте один тип кавычек. В этом воркшопе мы будем использовать только одинарные кавычки. + +## Условие задачи: + +Для решения данной задачи создайте файл `strings.js`. + +В этом файле объявите переменную `someString` таким образом: + +```js +const someString = 'this is a string' +``` + +Воспользуйтесь командой `console.log()`, чтобы вывести значение переменной **someString** в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify strings.js +``` diff --git a/problems/strings/problem_uk.md b/problems/strings/problem_uk.md new file mode 100644 index 00000000..d4013448 --- /dev/null +++ b/problems/strings/problem_uk.md @@ -0,0 +1,29 @@ +**Рядком (String)** є будь-яке значення огорнуте в лапки. + +Це можуть бути або одинарні, або подвійні дужки: + +```js +'this is a string' + +"this is also a string" +``` + +## ЗАУВАЖЕННЯ + +Спробуйте залишаться послідовними. У цьому воркшопі ми будемо використовувати лише одинарні лапки. + +## Завдання: + +Для цього завдання створіть файл `strings.js`. + +У цьому файлі створіть змінну `someString` ось так: + +```js +const someString = 'this is a string' +``` + +Використайте `console.log`, щоб вивести змінну **someString** до терміналу. + +Перевірте вашу відповідь запустивши команду: + +`javascripting verify strings.js` diff --git a/problems/strings/problem_zh-cn.md b/problems/strings/problem_zh-cn.md index f61474b5..d02a133d 100644 --- a/problems/strings/problem_zh-cn.md +++ b/problems/strings/problem_zh-cn.md @@ -1,7 +1,3 @@ ---- - -# 字符串 - **字符串**就是被引号包裹起来的任意的值。 单引号或双引号效果是一样的: @@ -11,7 +7,8 @@ "this is also a string" ``` -# 注 + +## 注 为了保持一致的风格,本教程中我们将只使用单引号。 @@ -22,7 +19,7 @@ 在文件中像这样创建一个名为 `someString` 的变量: ```js -var someString = 'this is a string'; +const someString = 'this is a string' ``` 使用 `console.log` 打印变量 **someString** 到终端。 @@ -30,5 +27,3 @@ var someString = 'this is a string'; 运行下面的命令来检查你的程序是否正确: `javascripting verify strings.js` - ---- diff --git a/problems/strings/problem_zh-tw.md b/problems/strings/problem_zh-tw.md new file mode 100644 index 00000000..2a27e7eb --- /dev/null +++ b/problems/strings/problem_zh-tw.md @@ -0,0 +1,29 @@ +**字串**就是被引號包裹起來的任意的值。 + +單引號或雙引號效果是一樣的: + +```js +'this is a string' + +"this is also a string" +``` + +## 注 + +為了保持一致的風格,本教學中我們將只使用單引號。 + +## 挑戰: + +建立一個名為 `strings.js` 的檔案。 + +在該檔案中像這樣建立一個名為 `someString` 的變數: + +```js +const someString = 'this is a string' +``` + +使用 `console.log` 印出變數 **someString** 到終端機上。 + +執行下面的命令來檢查你寫的程式是否正確: + +`javascripting verify strings.js` diff --git a/problems/strings/solution_fr.md b/problems/strings/solution_fr.md new file mode 100644 index 00000000..46aaa38e --- /dev/null +++ b/problems/strings/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# SUCCÈS + +Vous vous habituez aux chaînes de caractères ! + +Dans le défi suivant, nous découvrirons comment manipuler des chaînes de caractères. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/strings/solution_it.md b/problems/strings/solution_it.md new file mode 100644 index 00000000..9547ea99 --- /dev/null +++ b/problems/strings/solution_it.md @@ -0,0 +1,11 @@ +--- + +# VITTORIA. + +Ti stai abituando a queste stringhe! + +Nelle prossime sfide ci occuperemo di come manipolare le stringhe. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/strings/solution_nb-no.md b/problems/strings/solution_nb-no.md new file mode 100644 index 00000000..74e01cda --- /dev/null +++ b/problems/strings/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# BESTÅTT! + +Du begynner å få taket på dette med strings! + +I den neste oppgaven skal vi se på å manipulere på stringer. + +Kjør `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/strings/solution_nl.md b/problems/strings/solution_nl.md new file mode 100644 index 00000000..a934ea93 --- /dev/null +++ b/problems/strings/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# SUCCESS. + +Je raakt al lekker gewend aan die strings! + +In volgende uitdagingen behandelen we hoe je strings kunt manipuleren. + +Run `javascripting` in de console om de volgende uitdaging te kiezen. + +--- diff --git a/problems/strings/solution_pt-br.md b/problems/strings/solution_pt-br.md new file mode 100644 index 00000000..c3dfab75 --- /dev/null +++ b/problems/strings/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# SUCESSO! + +Você tá pegando o jeito com as strings! + +Nos próximos desafios vamos aprender á manipular as strings. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/strings/solution_ru.md b/problems/strings/solution_ru.md new file mode 100644 index 00000000..2bc3c0fd --- /dev/null +++ b/problems/strings/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# УСПЕХ. + +Вы начали пользоваться строками! + +В следующей задаче мы рассмотрим, как можно изменять строки. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/strings/solution_uk.md b/problems/strings/solution_uk.md new file mode 100644 index 00000000..8c11ecd5 --- /dev/null +++ b/problems/strings/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# УСПІХ. + +Ви починаєте використовувати рядки! + +У наступному завданні ми розглянемо як маніпулювати рядками. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/strings/solution_zh-tw.md b/problems/strings/solution_zh-tw.md new file mode 100644 index 00000000..258a5afa --- /dev/null +++ b/problems/strings/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 成功。 + +你已經對字串的使用得心應手了! + +下一個挑戰裡,我們將看到如何對字串進行操作。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/problems/this/index.js b/problems/this/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/this/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/this/problem_fr.md b/problems/this/problem_fr.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_fr.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/problem_it.md b/problems/this/problem_it.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_it.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/problem_nl.md b/problems/this/problem_nl.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_nl.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/problem_pt-br.md b/problems/this/problem_pt-br.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_pt-br.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/problem_ru.md b/problems/this/problem_ru.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_ru.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/problem_uk.md b/problems/this/problem_uk.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_uk.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/problem_zh-tw.md b/problems/this/problem_zh-tw.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/problem_zh-tw.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_fr.md b/problems/this/solution_fr.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_fr.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_it.md b/problems/this/solution_it.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_it.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_nl.md b/problems/this/solution_nl.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_nl.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_pt-br.md b/problems/this/solution_pt-br.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_pt-br.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_ru.md b/problems/this/solution_ru.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_ru.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_uk.md b/problems/this/solution_uk.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_uk.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/this/solution_zh-tw.md b/problems/this/solution_zh-tw.md new file mode 100644 index 00000000..09d67ae1 --- /dev/null +++ b/problems/this/solution_zh-tw.md @@ -0,0 +1,5 @@ +--- + +# + +--- diff --git a/problems/variables/index.js b/problems/variables/index.js deleted file mode 100644 index 706d66c2..00000000 --- a/problems/variables/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports = require("../../lib/problem")(__dirname) \ No newline at end of file diff --git a/problems/variables/problem.md b/problems/variables/problem.md index afae55fd..4225c822 100644 --- a/problems/variables/problem.md +++ b/problems/variables/problem.md @@ -1,13 +1,9 @@ ---- - -# VARIABLES - -A variable is a name that can reference a specific value. Variables are declared using `var` followed by the variable's name. +A variable is a name that can reference a specific value. Variables are declared using `let` followed by the variable's name. Here's an example: ```js -var example; +let example ``` The above variable is **declared**, but it isn't defined (it does not yet reference a specific value). @@ -15,12 +11,12 @@ The above variable is **declared**, but it isn't defined (it does not yet refere Here's an example of defining a variable, making it reference a specific value: ```js -var example = 'some string'; +const example = 'some string' ``` # NOTE -A variable is **declared** using `var` and uses the equals sign to **define** the value that it references. This is colloquially known as "Making a variable equal a value". +A variable is **declared** using `let` and uses the equals sign to **define** the value that it references. This is colloquially known as "Making a variable equal a value". ## The challenge: @@ -35,4 +31,3 @@ Then use `console.log()` to print the `example` variable to the console. Check to see if your program is correct by running this command: `javascripting verify variables.js` ---- diff --git a/problems/variables/problem_es.md b/problems/variables/problem_es.md index 233cdd3d..9b5104b5 100644 --- a/problems/variables/problem_es.md +++ b/problems/variables/problem_es.md @@ -1,12 +1,8 @@ ---- - -# VARIABLES - -Una variable es una referencia a un valor. Define una variable usando la palabra reservada `var`. +Una variable es una referencia a un valor. Define una variable usando la palabra reservada `let`. Por ejemplo: ```js -var example; +let example ``` La variable anterior es **declarada**, pero no definida. @@ -14,10 +10,10 @@ La variable anterior es **declarada**, pero no definida. A continuación damos un ejemplo de cómo definir una variable, haciendo que referencie a un valor específico: ```js -var example = 'some string'; +const example = 'some string' ``` -Nota que empieza con la palabra reserva `var` y usa el signo de igualdad entre en nombre de la variable y el valor que referencia. +Nota que empieza con la palabra reserva `let` y usa el signo de igualdad entre en nombre de la variable y el valor que referencia. ## El ejercicio @@ -32,4 +28,3 @@ Luego usa `console.log()` para imprimir la variable `example` a la consola. Comprueba si tu programa es correcto ejecutando el siguiente comando: `javascripting verify variables.js` ---- diff --git a/problems/variables/problem_fr.md b/problems/variables/problem_fr.md new file mode 100644 index 00000000..796f192e --- /dev/null +++ b/problems/variables/problem_fr.md @@ -0,0 +1,33 @@ +Une variable est un nom qui fait référence à une valeur spécifique. Les variables sont déclarées en utilisant le mot clé `let` suivi du le nom de la variable. + +Voici un exemple : + +```js +let example +``` + +La variable ci-dessus est **déclarée**, mais elle n'est pas définie ( elle ne référence aucune valeur pour le moment ). + +Voici un exemple de définition de variable, la faisant contenir une valeur spécifique : + +```js +const example = 'some string' +``` + +# NOTE + +Une variable est **déclarée** en utilisant `let` et utilise le signe égal pour **assigner** la valeur qu'elle référence. Nous utilisons communément l'expression "Assigner une valeur à une variable". + +## Le défi : + +Créez un fichier nommé `variables.js`. + +Dans ce fichier, déclarez une variable nommée `example`. + +**Assignez la valeur `'some string'` à la variable `example`.** + +Utilisez ensuite `console.log()` pour afficher la variable `example` dans la console. + +Vérifiez si votre programme est correct en exécutant la commande : + +`javascripting verify variables.js` diff --git a/problems/variables/problem_it.md b/problems/variables/problem_it.md new file mode 100644 index 00000000..121a2e50 --- /dev/null +++ b/problems/variables/problem_it.md @@ -0,0 +1,33 @@ +Una variabile è un nome che può fare riferimento a un valore specifico. Le variabili sono dichiarate usando `let` seguito dal nome della variabile. + +Ecco un esempio: + +```js +let example +``` + +La variabile precedente è stata **dichiarata**, ma non è stata definita (non fa ancora riferimento a un valore specifico). + +Ecco un esempio di definizione di una variabile, che le fa assumere un valore specifico: + +```js +const example = 'some string' +``` + +# NOTA + +Una variabile è **dichiarata** usando `let` e usa il segno uguale per **definire** il valore che rappresenta. Questa operazione è nota con l'espressione colloquiale "assegnare un valore a una variabile". + +## La sfida: + +Crea un file chiamato `variables.js`. + +In questo file dichiara una variabile chiamata `example`. + +**Assegua il valore `'some string'` alla variabile `example`.** + +Quindi usa `console.log()` per stampare la variabile `example` sulla console. + +Verifica che il tuo programma sia corretto eseguendo questo comando: + +`javascripting verify variables.js` diff --git a/problems/variables/problem_ja.md b/problems/variables/problem_ja.md index 104ec183..89b1f6e3 100644 --- a/problems/variables/problem_ja.md +++ b/problems/variables/problem_ja.md @@ -1,13 +1,9 @@ ---- - -# 変数 - -変数は特定の値を示す名前です。 `var` を使って変数を宣言します。 `var` につづけて変数の名前を書きます。 +変数は特定の値を示す名前です。 `let` を使って変数を宣言します。 `let` につづけて変数の名前を書きます。 例... ```js -var example; +let example ``` 上の例は変数を**宣言**しています。しかし、定義していません(この変数はまだなんの値も示しません)。 @@ -15,10 +11,10 @@ var example; 次の例は変数を定義します。定義した変数は特定の値を示します。 ```js -var example = 'some string'; +const example = 'some string' ``` -`var` を使って**宣言**します。つづいて、等号を使い、変数が示す値を**定義**します。 +`let` を使って**宣言**します。つづいて、等号を使い、変数が示す値を**定義**します。 これを「変数に値を代入する」と言います。 @@ -35,5 +31,3 @@ var example = 'some string'; 次のコマンドを実行し、あなたのプログラムが正しく動くか確認しましょう。 `javascripting verify variables.js` - ---- diff --git a/problems/variables/problem_ko.md b/problems/variables/problem_ko.md index a524eccc..146b058c 100644 --- a/problems/variables/problem_ko.md +++ b/problems/variables/problem_ko.md @@ -1,13 +1,9 @@ ---- - -# 변수 - -변수는 특정 값을 참조하는 이름입니다. 변수는 `var`와 변수의 이름으로 선언합니다. +변수는 특정 값을 참조하는 이름입니다. 변수는 `let`와 변수의 이름으로 선언합니다. 예제를 보세요. ```js -var example; +let example ``` 위 변수는 **선언**되었지만, 정의되지는 않았습니다.(아직 특정 값을 참조하지 않았습니다.) @@ -15,12 +11,12 @@ var example; 특정 값을 참조하게 만든, 변수를 정의하는 예제입니다. ```js -var example = 'some string'; +const example = 'some string' ``` # 주의 -변수는 `var`를 사용해 **선언**하고 등호(`=`)를 이용해 참조하는 값을 넣어 **정의**합니다. "변수는 값과 같게 만든다."라고 읽을 수 있습니다. +변수는 `let`를 사용해 **선언**하고 등호(`=`)를 이용해 참조하는 값을 넣어 **정의**합니다. "변수는 값과 같게 만든다."라고 읽을 수 있습니다. ## 도전 과제 @@ -36,4 +32,3 @@ var example = 'some string'; 이 명령어를 실행해 프로그램이 올바른지 확인하세요. `javascripting verify variables.js` ---- diff --git a/problems/variables/problem_nb-no.md b/problems/variables/problem_nb-no.md new file mode 100644 index 00000000..ffe17a1a --- /dev/null +++ b/problems/variables/problem_nb-no.md @@ -0,0 +1,33 @@ +En variabel er et navn som kan peke til en spesifikk verdi. Variables deklareres ved å bruke `let` etterfulgt av variablens navn. + +Her er et eksempel: + +```js +let example +``` + +Variabelen over er **deklarert**, men den er ikke definert (den peker ikke til en spesifikk verdi ennå). + +Her er et eksempel som definerer en variabel, ved å peke til en spesifikk verdi: + +```js +const example = 'some string' +``` + +# OBS + +En variabel blir **deklarert** ved bruk av `let` og erlikhetstegn til å **definere** verdien den peker til. Dette kalles som oftes å "sette verdien til en variabel". + +## Oppgaven: + +Lag en fil som heter `variables.js`. + +I den filen skal det deklareres en variabel med navnet `example`. + +**Sett verdien `'some string'` inn i variabelen `example`.** + +For å skrive ut verdien til `example` til skjermen bruk `console.log()`. + +Se om programmet ditt er riktig ved å kjøre denne kommandoen: + +`javascripting verify variables.js` diff --git a/problems/variables/problem_nl.md b/problems/variables/problem_nl.md new file mode 100755 index 00000000..456f700e --- /dev/null +++ b/problems/variables/problem_nl.md @@ -0,0 +1,33 @@ +Een variabele is een naam die kan verwijzen naar een specifieke waarde. Variabelen worden gedeclareerd met `let` gevolgd door de naam van de variabele. + +Hier is een voorbeeld: + +```js +let example +``` + +De variabele hierboven is **gedeclareerd**, maar nog niet gedefinieerd (de variabel verwijst nog niet naar een specifieke waarde). + +Hier is een voorbeeld van het definiëren van een variabele die naar een specifieke waarde verwijst: + +```js +const example = 'some string' +``` + +# OPMERKING + +Een variabele wordt **gedeclareerd** met `let` en gebruikt "=" om de waarde te **definiëren** waar het naar verwijst. Dit noem je ook wel "Een variabele gelijk maken aan een waarde". + +## De uitdaging: + +Maak een bestand met de naam `variables.js`. + +Declareer een variabele in dit bestand met de naam `example`. + +**Maak de variabele `example` gelijk aan de waarde `'some string'`.** + +Gebruik nu `console.log()` om de `example` variable naar console te printen. + +Controleer of je programma goed werkt met dit commando: + +`javascripting verify variables.js` diff --git a/problems/variables/problem_pt-br.md b/problems/variables/problem_pt-br.md new file mode 100644 index 00000000..9fbbddc7 --- /dev/null +++ b/problems/variables/problem_pt-br.md @@ -0,0 +1,35 @@ +Uma variável é o nome que pode fazer referência a um valor específico. Variáveis são declaradas usando a palavra `let` seguida do nome da variável. + +Aqui está um exemplo: + +```js +let example +``` + +A variável acima foi **declarada**, mas ainda não foi definida (ou seja, ainda não faz referência á um valor específico). + +Aqui está um exemplo de como definir uma variável, fazendo ela referenciar um valor específico: + +```js +const example = 'some string' +``` + +# OBSERVAÇÃO + +Um variável é **declarada** quando usamos `let`, e o `=` é usado para **definir** o valor pelo qual a variável vai fazer referência. + +Coloquialmente dizemos que "criamos uma variável com um valor". + +## Desafio: + +Crie um arquivo chamado `variables.js`. + +No arquivo que foi criado declare uma variável chamada `example`. + +**Faça a variável `example` ter o valor igual á `'some string'`.** + +Então use o `console.log()` para imprimir a variável `example` no console. + +Verifique se o seu programa está correto executando este comando: + +`javascripting verify variables.js` diff --git a/problems/variables/problem_ru.md b/problems/variables/problem_ru.md new file mode 100644 index 00000000..ba59ea26 --- /dev/null +++ b/problems/variables/problem_ru.md @@ -0,0 +1,35 @@ +Переменная -- это имя, с которым связано определённое значение. Переменные объявляются с помощью ключевого слова `let`, после которого записывается название переменной. + +Например: + +```js +let example +``` + +Переменная выше **объявлена**, но не задана (ей не присвоено какое-либо конкретное значение). + +Ниже дан пример объявления переменной с заданным значением: + +```js +const example = 'some string' +``` + +## НА ЗАМЕТКУ + +Ключевое слово `let` используется чтобы **объявить** переменную, а знак _равно_ используется для того, чтобы **присвоить** значение этой переменной. + +## Условие задачи: + +Создайте файл под названием `variables.js`. + +Объявите переменную под названием `example` в этом файле. + +**Присвойте значение `'some string'` переменной `example`.** + +Воспользуйтесь командой `console.log()`, чтобы вывести значение переменной `example` в консоль. + +Чтобы удостовериться в правильности решения задачи, запустите следующую команду из терминала: + +```bash +javascripting verify variables.js +``` diff --git a/problems/variables/problem_uk.md b/problems/variables/problem_uk.md new file mode 100644 index 00000000..5cc3ade0 --- /dev/null +++ b/problems/variables/problem_uk.md @@ -0,0 +1,33 @@ +Змінною називають ім’я, яке посилається на певне значення. Змінні оголошуються з допомогою ключового слова `let`, за яким слідує ім’я змінної. + +Приклад оголошення змінної: + +```js +let example +``` + +У прикладі вище, змінна **оголошена (declared)**, проте не була визначеною (defined) (тобто вона поки не посилається на конкретне значення). + +Ось приклад визначення змінних, посилання на певне значення: + +```js +const example = 'some string' +``` + +# ЗАУВАЖЕННЯ + +Змінна **оголошена** з допомогою `let` та якій **присвоєно** посилання на значення з допомогою оператора присвоєння, буде посилатись на це значення. Також це називають «Присвоєнням змінній значення». + +## Завдання: + +Створити файл `variables.js`. + +У цьому файлі оголосити змінну `example`. + +**Присвойте змінній `example` значення `'some string'`.** + +Використайте `console.log()`, щоб вивести змінну `example` до консолі. + +Перевірте вашу відповідь запустивши команду: + +`javascripting verify variables.js` diff --git a/problems/variables/problem_zh-cn.md b/problems/variables/problem_zh-cn.md index cbc3977a..1223096f 100644 --- a/problems/variables/problem_zh-cn.md +++ b/problems/variables/problem_zh-cn.md @@ -1,13 +1,9 @@ ---- - -# 变量 - -变量就是一个可以引用具体值的名字。变量通过使用 `var` 及紧随其后的变量名来声明。 +变量就是一个可以引用具体值的名字。变量通过使用 `let` 及紧随其后的变量名来声明。 下面是一个例子: ```js -var example; +let example ``` 这个例子里的变量被**声明**,但是没有被定义(也就是说,它目前还没有引用一个值)。 @@ -16,12 +12,12 @@ var example; ```js -var example = 'some string'; +const example = 'some string' ``` # 注 -变量通过 `var` 来**声明**,并通过等号来**定义**它的值。这也就是经常提到的“让一个变量等于一个值(变量赋值)”。 +变量通过 `let` 来**声明**,并通过等号来**定义**它的值。这也就是经常提到的“让一个变量等于一个值(变量赋值)”。 ## 挑战: @@ -36,4 +32,3 @@ var example = 'some string'; 运行下面的命令来检查你的程序是否正确: `javascripting verify variables.js` ---- diff --git a/problems/variables/problem_zh-tw.md b/problems/variables/problem_zh-tw.md new file mode 100644 index 00000000..1adc4b13 --- /dev/null +++ b/problems/variables/problem_zh-tw.md @@ -0,0 +1,34 @@ +變數就是一個可以引用具體值的名字。變數通過使用 `let` 及緊隨其後的變數名來宣告。 + +下面是一個例子: + +```js +let example +``` + +這個例子裡的變數被**宣告**,但是沒有被定義(也就是說,它目前還沒有引用一個值)。 + +下面是一個定義變數的例子,這樣變數將會有一個值: + + +```js +const example = 'some string' +``` + +# 注 + +變數通過 `let` 來**宣告**,並通過等號來**定義**它的值。這也就是經常提到的「讓一個變數等於一個值」。 + +## 挑戰: + +建立一個名為 `variables.js` 的檔案。 + +在該檔案中宣告一個名為 `example` 的變數。 + +**讓變數 `example` 等於值 `'some string'`。** + +然後使用 `console.log()` 印出 `example` 變數到終端機上。 + +執行下面的命令來檢查你寫的程式是否正確: + +`javascripting verify variables.js` diff --git a/problems/variables/solution_es.md b/problems/variables/solution_es.md index 1e828b4f..1d7b0ce6 100644 --- a/problems/variables/solution_es.md +++ b/problems/variables/solution_es.md @@ -6,6 +6,6 @@ Buen trabajo. En el siguiente ejercicio trabajaremos más en profundidad con strings. -Ejecuta `javascripting` en la terminal para seleccionar el sigueinte ejercicio. +Ejecuta `javascripting` en la terminal para seleccionar el siguiente ejercicio. --- diff --git a/problems/variables/solution_fr.md b/problems/variables/solution_fr.md new file mode 100644 index 00000000..f5bd7827 --- /dev/null +++ b/problems/variables/solution_fr.md @@ -0,0 +1,11 @@ +--- + +# VOUS AVEZ CRÉÉ UNE VARIABLE ! + +Bon boulot. + +Dans le prochain défi, nous étudierons les chaînes de caractères de façon plus précise. + +Exécutez `javascripting` dans la console pour choisir le prochain défi. + +--- diff --git a/problems/variables/solution_it.md b/problems/variables/solution_it.md new file mode 100644 index 00000000..9dd4ad3d --- /dev/null +++ b/problems/variables/solution_it.md @@ -0,0 +1,11 @@ +--- + +# HAI CREATO UNA VARIABILE! + +Ben fatto. + +Nella prossima sfida daremo uno sguardo approfondito alle stringhe. + +Esegui `javascripting` nella console per scegliere la prossima sfida. + +--- diff --git a/problems/variables/solution_nb-no.md b/problems/variables/solution_nb-no.md new file mode 100644 index 00000000..e95b90f8 --- /dev/null +++ b/problems/variables/solution_nb-no.md @@ -0,0 +1,11 @@ +--- + +# DU LAGDE EN VARIABEL! + +Bra jobbet. + +I den neste oppgaven skal vi se mer på stringer. + +Kjør kommandoen `javascripting` i terminalen for å velge neste oppgave. + +--- diff --git a/problems/variables/solution_nl.md b/problems/variables/solution_nl.md new file mode 100644 index 00000000..045d2280 --- /dev/null +++ b/problems/variables/solution_nl.md @@ -0,0 +1,11 @@ +--- + +# JE HEBT EEN VARIABELE GEMAAKT! + +Goed gedaan. + +In de volgende uitdaging gaan we *strings* nog verder bekijken. + +Voer het commando `javascripting` in de console uit om de volgende uitdaging te kiezen. + +--- diff --git a/problems/variables/solution_pt-br.md b/problems/variables/solution_pt-br.md new file mode 100644 index 00000000..225d66e1 --- /dev/null +++ b/problems/variables/solution_pt-br.md @@ -0,0 +1,11 @@ +--- + +# VOCÊ CRIOU UMA VARIÁVEL! + +Bom trabalho! + +No próximo desafio vamos dar uma olhada mais de perto nas strings. + +Execute `javascripting` no console para escolher o próximo desafio. + +--- diff --git a/problems/variables/solution_ru.md b/problems/variables/solution_ru.md new file mode 100644 index 00000000..84f97359 --- /dev/null +++ b/problems/variables/solution_ru.md @@ -0,0 +1,11 @@ +--- + +# ВЫ СОЗДАЛИ ПЕРЕМЕННУЮ! + +Отличная работа. + +В следующей задаче мы более подробно разберём работу со строками. + +Запустите `javascripting` в консоли и выберите следующую задачу. + +--- diff --git a/problems/variables/solution_uk.md b/problems/variables/solution_uk.md new file mode 100644 index 00000000..e2b00a93 --- /dev/null +++ b/problems/variables/solution_uk.md @@ -0,0 +1,11 @@ +--- + +# ВИ СТВОРИЛИ ЗМІННУ! + +Добре впорались. + +У наступному завданні ми ближче познайомимось з рядками. + +Запустіть 'javascripting' в консолі, щоб обрати наступне завдання. + +--- diff --git a/problems/variables/solution_zh-tw.md b/problems/variables/solution_zh-tw.md new file mode 100644 index 00000000..c604fd6f --- /dev/null +++ b/problems/variables/solution_zh-tw.md @@ -0,0 +1,11 @@ +--- + +# 你建立了一個變數! + +幹得漂亮。 + +下一個挑戰中我們將進一步地探究字串。 + +運行 `javascripting` 並選擇下一個挑戰。 + +--- diff --git a/solutions/accessing-array-values/index.js b/solutions/accessing-array-values/index.js index 55ebd76c..eadb700e 100644 --- a/solutions/accessing-array-values/index.js +++ b/solutions/accessing-array-values/index.js @@ -1,3 +1,3 @@ -var food = ['apple', 'pizza', 'pear']; +const food = ['apple', 'pizza', 'pear'] -console.log(food[1]); \ No newline at end of file +console.log(food[1]) diff --git a/solutions/array-filtering/index.js b/solutions/array-filtering/index.js index b65e18cd..81697601 100644 --- a/solutions/array-filtering/index.js +++ b/solutions/array-filtering/index.js @@ -1,7 +1,7 @@ -var numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; +const numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] -var filtered = numbers.filter(function (number) { - return (number % 2) === 0; -}); +const filtered = numbers.filter(function (number) { + return (number % 2) === 0 +}) -console.log(filtered); +console.log(filtered) diff --git a/solutions/arrays/index.js b/solutions/arrays/index.js index 9eb1ab2d..ca4817f2 100644 --- a/solutions/arrays/index.js +++ b/solutions/arrays/index.js @@ -1,2 +1,2 @@ -var pizzaToppings = ['tomato sauce', 'cheese', 'pepperoni']; -console.log(pizzaToppings); \ No newline at end of file +const pizzaToppings = ['tomato sauce', 'cheese', 'pepperoni'] +console.log(pizzaToppings) diff --git a/solutions/for-loop/index.js b/solutions/for-loop/index.js index f5ce68da..d3d7b7bc 100644 --- a/solutions/for-loop/index.js +++ b/solutions/for-loop/index.js @@ -1,8 +1,8 @@ -var total = 0; -var limit = 10; +let total = 0 +const limit = 10 -for (var i = 0; i < limit; i++) { - total += i; +for (let i = 0; i < limit; i++) { + total += i } console.log(total) diff --git a/solutions/function-arguments/index.js b/solutions/function-arguments/index.js index 8601d86d..226d8916 100644 --- a/solutions/function-arguments/index.js +++ b/solutions/function-arguments/index.js @@ -1,5 +1,5 @@ -function math(a, b, c) { - return (b * c) + a; +function math (a, b, c) { + return (b * c) + a } -console.log(math(53, 61, 67)); \ No newline at end of file +console.log(math(53, 61, 67)) diff --git a/solutions/functions/index.js b/solutions/functions/index.js index 13021984..e3737432 100644 --- a/solutions/functions/index.js +++ b/solutions/functions/index.js @@ -1,5 +1,5 @@ function eat (food) { - return food + ' tasted really good.'; + return food + ' tasted really good.' } -console.log(eat('bananas')); \ No newline at end of file +console.log(eat('bananas')) diff --git a/solutions/if-statement/index.js b/solutions/if-statement/index.js index 830656f0..94fdd1cd 100644 --- a/solutions/if-statement/index.js +++ b/solutions/if-statement/index.js @@ -1,6 +1,6 @@ -var fruit = 'orange'; +const fruit = 'orange' if (fruit.length > 5) { - console.log('The fruit name has more than five characters.'); + console.log('The fruit name has more than five characters.') } else { - console.log('The fruit name has five characters or less.'); + console.log('The fruit name has five characters or less.') } diff --git a/solutions/introduction/index.js b/solutions/introduction/index.js index e921523b..371fdfb1 100644 --- a/solutions/introduction/index.js +++ b/solutions/introduction/index.js @@ -1 +1 @@ -console.log('hello'); +console.log('hello') diff --git a/solutions/looping-through-arrays/index.js b/solutions/looping-through-arrays/index.js index bd242e35..6089e11f 100644 --- a/solutions/looping-through-arrays/index.js +++ b/solutions/looping-through-arrays/index.js @@ -1,7 +1,7 @@ -var pets = ['cat', 'dog', 'rat']; +const pets = ['cat', 'dog', 'rat'] -for (var i=0; i