Answer:
The answer to this question is given below in the explanation section
Explanation:
There are different skills or passions that you can use to earn handsome money.
Being a computer student, I have a passion for web development. I have skills in Wordpress, HTML and PHP. I used these skills to develop static and dynamic websites for clients and for companies.
Even, If I will not get a job in some companies and I want to work online according to my own pace and time. I can use freelancing, and doing the online job and providing services to clients online, I can earn more money than doing a traditional job.
It was the whaling industry.
Whaling use to be the main source of oil that was used for fuel and
lighting in America which was based in the coastal communities of New England. It went into decline when oil was discovered
in 1859. Eventually it replaced whale
oil as a source of fuel and life.
Answer:
userInput = str(input("Enter your sentence here.\n")).upper()
def getPigLatin(userInput):
splitInput = userInput.split(" ")
newList = []
for word in splitInput:
firstLetter = word[0]
if len(word) == 1:
word += 'AY'
newList.append(word)
else:
word = word.strip(word[0])
word += firstLetter
word += 'AY'
newList.append(word)
print(*newList, sep= " ")
getPigLatin(userInput)
Explanation:
This solution is done in Python
First the user is prompt to enter a statement, the statement converted to string and also capitalize using str and upper() built-in function. The user input is assigned to userInput variable.
The getPigLatin function is defined and it accept a string as parameter. Inside the getPigLatin function, the userInput is splitted and assigned to splitInput variable.
An empty list is also initialized and assigned to newList. Next, we loop through the splitInput. During the loop; we first check if the length of an element is one, then we just add 'AY' to the element and add the element to the newList. Else, if the element length is more than one; we strip the first letter from the word and also re-assign it to word, then the stripped first letter is added to the end of the word. Next, 'AY' is added to the word and the element is add to the newList.
The last line of the getPigLatin function display the entire element of the list using a space seperator.
The last line of the entire solution call the function passing in the userInput as argument.
1 because when you type on the home row your left middle finger will hit both of those letters.