-
-
Notifications
You must be signed in to change notification settings - Fork 531
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 Capitalize in C #1516
Added Capitalize in C #1516
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't look like we have any formal tests for this, so this looks good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aborting review. Already merged.
int main(int argc, char *argv[]) { | ||
if(argc == 2) { | ||
printf("Result: %s\n", captialize(argv[1])); | ||
} else if(argc > 2) { | ||
printf("Use quotes around multiple strings.\n"); | ||
} else { | ||
printf("Expected an argument.\n"); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The requirements call out that there should be a check to verify the the input is a string and not a number. Can that check be added here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Disregard.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is probably a good opportunity to put together some formal tests in the documentation. I've put it off because @auroq usually helps us write those, but we can do that!
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
Added/Updated <Sample Program> in <Language>
formatDocumentation
Added/Updated <Sample Program> in <Language> Article
formatTesting
Added/Updated <Language>/<Project> Testing
formatNotes
Feel free to describe what you added or updated.