Code Monkey home page Code Monkey logo

rd-challenge's Introduction

rd-challenge

The Challenge

The solution implemented in this repository, solves the problem proposed of CustomerSuccess Balancing.

The main (execute) function solves the problem in two larger steps:

  1. Group for each customer success an array of scores from the respective customers;
  2. From the defined grouping, find the id of the customer success that has the largest number of customers.

Other Ruby resources and auxiliary functions are used to assist in each of the problem solving steps.

Six more test cases were added, following the same pattern in this project.

Application files and test files are separated into directories for better organization.

Versions

A version of Ruby โ€‹โ€‹was used through the manager RVM:

  • rvm 1.29.12
  • ruby-3.0.2

Run

In the project folder, you need access the test folder and execute the test with the following command:

  • ruby test/customer_success_balancing_tests.rb

Next Steps

  • Maybe use a more resourceful gem for testing (RSpec) and follow a convention for using it like BetterSpecs.

rd-challenge's People

Watchers

Italo Menna Silveira 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.