Skip to content

sei-eternity/hw-w01d03-js-functions

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

General Assembly Logo

JS Functions HW

Instructions

  1. Fork and clone this repository.
  2. Change into the new directory.
  3. Create and checkout a new branch, named response.
  4. When finished, git add, git commit, git push to your fork and submit a pull request.

Questions

  1. Dice Roller

    • You can put your work in the dice.js file.
    • Write a function that chooses two random numbers (1-6) and returns them. It should also return the sum.
    • Example: rollDice() // Dice rolled are 6 and 1. Sum is 7
    • BONUS: have your function take an argument of the # of dice to be rolled.
    • Example: rollDice(3) // Dice rolled are 4, 2, and 7. Sum is 13.
  2. Research 3 string methods and describe what they are used for and how to use them. You can find string methods here https://www.w3schools.com/js/js_string_methods.asp

Method 1

Name:
Description:
Example using it:

Method 2

Name:
Description:
Example using it:

Method 3

Name:
Description:
Example using it:
  1. All content is licensed under a CC­BY­NC­SA 4.0 license.
  2. All software code is licensed under GNU GPLv3. For commercial use or alternative licensing, please contact [email protected].

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • HTML 91.4%
  • JavaScript 8.6%