GithubHelp home page GithubHelp logo

fe2-audit's Introduction

Week 3 Audit

Fork this repo (do not clone), then clone your forked copy to your machine.

cd into the directory for this project

Run npm install to install dependencies

All work should be completed in the index.js file

You will have one hour to complete these exercises.

Once you have completed your work, push it up to GitHub and DM the link of your GitHub repo to your instructor.


For each context exercise

We want to know what the value of this is when a certain piece of code is executed. This might be a standalone function or a method on an object.

Your result should be a string in one of the following formats:

'global window object'  
'nameOfObject'  
'instance of nameOfClassInstance'  

Your answer should be assigned to the result variable.


For each scope exercise

We what to know the order of the logs and their values. In the event that the value of a variable would be undefined or the code would throw an error, write your answer like so:

const result = [  
 { ‘A’: ‘reference error’ },  
 { ‘B’: undefined },  
 { ‘C’: ‘bar’ }. 
 …etc  
]. 

Your answer should be assigned to the result variable.


For the prototype exercises, you will want to assign your solution to the variable result.

An example of what your solution might look like can be found below:

// ./index.js
const { animals } = require('./datasets/farm');

const farmPrompts = {
  totalFarmAnimals() {
    // Return a single number that represents the
    // total amount of animals on the farm. e.g.
    // 50

    const result = animals.reduce((total, animal) => {
      return total += animal.count;
    }, 0);

    return result;

  }
}

--

For Bonus Exercise

If you have time, please read through the directions in index.js to complete the bonus exercise

fe2-audit's People

Contributors

thatpamiam avatar laurenlucero avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.