Created
July 14, 2017 14:22
-
-
Save isaquealves/2c4f8563a0c8f0116db29eaa647eb6e1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# this works for Bash and Zsh shell | |
a=("it is true for all that that that that that that that refers to is not the same that that that that refers to") | |
# Use this with Fish shell | |
# set a "it is true for all that that that that that that that refers to is not the same that that that that refers to" | |
# or if you need to count words in a sample file, | |
# cat <file> | tr " " "\n" | sort -n | uniq -c | |
echo "$a" | tr " " "\n" | sort -n | uniq -c |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment