Skip to content

AdityaCH1997/ccwc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

ccwc

WC - John Crickett's Coding Challenge #1

This is an implementation of the Unic command line tool wc. This is a solution to the Week 1 problem in John Crickett's Coding Challenges.

Getting Started

  1. Clone Repository:

    git clone https://github.com/AdityaCH1997/ccwc.git
    cd ccwc
  2. Check If Script is executable:

    ls -al

    If script does not have x in the permissions add permission using following command

    chmod +x ccwc.sh
  3. Source Script:

    source ccwc.sh
  4. Test Script:

    • Count the number of bytes in a file
    ccwc -c test.txt
    • Count the number of lines in a file
    ccwc -l test.txt
    • Count the number of characters in a file
    ccwc -m test.txt
    • Count the number of words in a file
    ccwc -w test.txt
    • Default count of lines, words and bytes in a file
    ccwc test.txt
    • Reading file from standard input when no filename is provided
    cat test.txt | ccwc -l
  5. Feel free to test further and add new functionalities

About

WC - John Crickett's Coding Challenge #1

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages