Skip to content

step818/WordCounterCsharp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Word Counter with C#

5th & 6th Independent project, 04/26/2019 - 05/05/2019

By Stephen Trewick

Program Name Word Counter 5th & 6th Independent Project

Description

This exercise is designed to take a word from a user and then a sentence that may have the word in it a certain number of times. The program will return to the user the amount of times the word is in their sentence. It will make sure that their word is not a part of another word. Test Methods are a large part of the practice of this exercise and DRYing up our code to be able to use and edit our methods without altering our Program code. The next large practice part of this project is building out an MVC web user interface.

Specs

Spec Input Output
Returns a number pertaining to the amount of times a word was found in a string. Input: "hat" Input: "That emphatic hateful manhattan chatterbox has a phat hat." Output: "You used "hat" 1 time."
Returns a number pertaining to the amount of times a word was found in a string if the word starts with an uppercase letter and the original word doesn't. Input: "is" Input: "Is this a persistent sunrise or is it going to end?" Output: "You used "is" 2 times.
Can account for numbers too, as long as the number isn't part of another word or number. Input: "2019" Input: "In 2019, I have been awake for 201958 hours." Output: "You used "2019" 1 time."
If a word isn't in the sentence, returns a message with 0. Input: "zero" Input: "How many times?" Output: "You used "zero" 0 times."
Counts words with mixed uppercase letters. Input: "funky" Input: "FuNkY behaviors call for fUnKy specs." Output: "You used "funky" 3 times."

Setup/Installation Requirements

You need a a terminal or command line and .Net Core 2.2 to be able to run the code

Support and contact details

stephent818@gmail.com

Technologies Used

_GIT Bash, , .NET-Sdk-2.2-x64 _

License

Licensed under the GPL License Copyright (c) 2019 Stephen Trewick

About

1st C# project

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published