How u convert string "hi pravin how are you?" to
"Hi Pravin How Are You?"
Answer Posted / vipul dalwala
echo "hi pravin how are you?" | awk 'BEGIN { ORS = ""
upper = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
lower = "abcdefghijklmnopqrstuvwxyz" }
{
for (i = 1; i <= NF; i++) {
FC = substr($i, 1, 1)
if (C = index(lower, FC))
FC = substr(upper, C, 1)
print FC substr($i,2) " "
}
print "\n"
}'
| Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
Devise a script that takes file name as arguement(which must present in the current directory)and locates from your home directory tree all thpath names of its links.Then mail the list to self.
Is shell scripting easy to learn?
Given a file find the count of lines containing the word "abc".
What can scripts do?
Explain how you Automate your application using Shell scripting.
Explain about non-login shell files?
What is the equivalent of a file shortcut that we have a window on a linux system?
In my bash shell I want my prompt to be of format '$"present working directory":"hostname"> and load a file containing a list of user-defined functions as soon as I log in, how will you automate this?
Is powershell a bash?
What is the best scripting language?
What is wc in shell script?
What language is bash written in?
How many fields are present in a crontab file and what does each field specify?
What does echo mean in scripting?
What is web script?