Giter Site home page Giter Site logo

bug-hide-n-seek's Introduction

bug-hide-n-seek

Just a challenge for my coding partner ๐Ÿค“

Hello partner ๐Ÿ–

This is just a little challenge I did when I was studying for the Micorverse Program admissions.

The function in the code is golf-result-giver, that means that depending on the parameters given to that function (strokes, par) you will have different results:

score = 1 "Hole-in-one!"

score <= par - 2 "Eagle"

score = par - 1 "Birdie"

score = par "Par"

score = par + 1 "Bogey"

score = par + 2 "Double Bogey"

score >= par + 3 "Go Home!"

Anyway... one of the test cases is strokes = 1 and par = 1. It should return "Hole-in-one!", but it's returning "Par". Let's see if you can find the problem. ๐Ÿคž

bug-hide-n-seek's People

Contributors

rpire avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

bug-hide-n-seek's Issues

Bug fixed

Hello Rubรฉn ๐Ÿ‘‹,

Even though my golf knowledge is limited, I was able to found the code and fix the bug!

Bug

I fixed the code by adding a condition on line 9 where it checks if (par === strokes) which states that par shouldn't be equal to 1.

Cheers and Happy coding! ๐Ÿš€

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.