Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Even/Odd in Ruby #1840

Merged
merged 4 commits into from
Nov 4, 2019
Merged

Added Even/Odd in Ruby #1840

merged 4 commits into from
Nov 4, 2019

Conversation

msj2
Copy link
Contributor

@msj2 msj2 commented Oct 31, 2019

Accept a number on command line and print if the number is Odd or Even

Congrats on taking the first step to contributing to the Sample Programs repository maintained by The Renegade Coder! For simplicity, please make sure that your pull request includes one and only one contribution.

Complete the Applicable Sections Below

Find which section best describes your pull request and make sure you fill it out. To start, let us know which issue you've fixed.

Code Snippets

  • I named the pull request using Added/Updated <Sample Program> in <Language> format
  • I created/updated the language README
    • I added the sample program name to the README
    • I added fun facts (i.e. debut, developer, typing, etc.)
    • I added reference link(s) to the README
    • I added solution citations when necessary (see plagiarism)

Documentation

  • I named the pull request using Added/Updated <Sample Program> in <Language> Article format
  • I followed the applicable article template

Testing

  • I named the pull request using Added/Updated <Language>/<Project> Testing format
  • I followed the testinfo template, if applicable

Notes

Added a program to accept a number on command line and print if it is Odd or Even

Accept a number on command line and print if the number is Odd or Even
@jrg94 jrg94 changed the title Check if number is Odd or Even Added Even/Odd in Ruby Oct 31, 2019
@msj2
Copy link
Contributor Author

msj2 commented Nov 1, 2019

I see the file name was wrong & has been corrected,

my bad.

Is there something I can do about it now?

@msj2 msj2 mentioned this pull request Nov 2, 2019
14 tasks
@jrg94 jrg94 requested a review from a team November 2, 2019 13:50
@jrg94 jrg94 self-assigned this Nov 2, 2019
@jrg94 jrg94 added enhancement Any code that improves the repo even odd See: https://sampleprograms.io/projects/even-odd/ labels Nov 2, 2019
@jrg94 jrg94 added this to the 500 Code Snippets milestone Nov 2, 2019
Copy link
Member

@jrg94 jrg94 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there are two test failing here.

  • Empty Input ("")
  • Invalid Input ("a")

Patch those cases, and we'll be good to go! 👍

Test Case 1: Send a String  and Test Case 2: Empty Value
@msj2
Copy link
Contributor Author

msj2 commented Nov 4, 2019

Hi Jeremy,

I learnt how to update in the Branch named patch-***
Test Case 1: Send a String
Test Case 2: Empty Value

I've handled these 2 Cases, placed the program invocation & Output in Program Header.

Kindly do check and Commit.

Error out for Strings
Copy link
Member

@jrg94 jrg94 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work!

@jrg94 jrg94 merged commit 8b5d451 into TheRenegadeCoder:master Nov 4, 2019
@msj2
Copy link
Contributor Author

msj2 commented Nov 5, 2019

Can hacktoberfest tag be added to this?

@jrg94 jrg94 added the hacktoberfest Hacktoberfest related label Nov 5, 2019
@msj2
Copy link
Contributor Author

msj2 commented Nov 6, 2019

thank you Jeremy.

I'll keep writing to this repo.

loved the travis thing it was good experience.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Any code that improves the repo even odd See: https://sampleprograms.io/projects/even-odd/ hacktoberfest Hacktoberfest related
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Add Odd or Even number checking program in Ruby
2 participants