Giter VIP home page Giter VIP logo

enumerables's Introduction

Contributors Forks Stargazers Issues


Phaser

ENUMERABLE METHOD

Report Bug Request Feature

This is the project to implement user defined Enumerable methods

  1. Create #my_each, a method that is identical to #each but (obviously) does not use #each. You’ll need to remember the yield statement. Make sure it returns the same thing as #each as well.
  2. Create #my_each_with_index in the same way.
  3. Create #my_select in the same way, though you may use #my_each in your definition (but not #each).
  4. Create #my_all? (continue as above)
  5. Create #my_any?
  6. Create #my_none?
  7. Create #my_count
  8. Create #my_map
  9. Create #my_inject
  10. Test your #my_inject by creating a method called #multiply_els which multiplies all the elements of the array together by using #my_inject, e.g. multiply_els([2,4,5]) #=> 40
  11. Modify your #my_map method to take a proc instead.
language used
  • Ruby

Author

👤 Salum Habibu

📝 License

This project is MIT licensed.

enumerables's People

Contributors

ibunhabibu avatar

Stargazers

Fernando Bahamondes avatar Marcelo Araújo avatar Nick A. Haralampopoulos avatar

Watchers

James Cloos avatar  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.