Answer:
ace, learn, memorize, comprehend
Explanation:
Spending more than you have and not paying it back on your bill.
<span>Open source software is usually free to download and install, and it can be studied, changed, and distributed according to the rights of the software. I don't believe there is any copyright laws on this type of software. The most known open source software is Linux and it's available for most operating systems right now. Typically, open source owners just ask for donations for their work.</span>
Answer:
def occurencesOfWords(words,freq):
frequency_dictionary={}
matched_frequency_words=[]
for i in range(len(words)):
counter=1
a=words[i].lower()
for j in range(len(words)):
if(i==j):
continue
b=words[j].lower()
if(a==b):
counter+=1
frequency_dictionary[words[i]]=counter
for key in frequency_dictionary:
if(frequency_dictionary[key]==freq):
matched_frequency_words.append(key)
return matched_frequency_words
if __name__=='__main__':
user_input=input()
freq=int(input())
words=user_input.split(" ");
required_words=occurencesOfWords(words,freq)
for s in required_words:
print(s)
Explanation:
- Inside the occurencesOfWords function, initialize a frequency_dictionary that is used to store the string and the frequency of that specific string
.
- matched_frequency_words is an array that is used to store each string whose frequency matches with the provided frequency
- Run a nested for loop up to the length of words and inside the nested for loop, skip the iteration if both variables i and j are equal as both strings are at same index.
- Increment the counter variable, if two string are equal.
- Loop through the frequency_dictionary to get the matching frequency strings
.
- Finally test the program inside the main function.
Answer:
Following are the output of the given question
3 4 6 8
Explanation:
In the following code, firstly, we have declare two integer data type "X" and "Y".
- Then, set two for loop in which first one is outer loop and the second one is the inner loop, inner loop starts from 1 and end at 2 and outer loop starts from 3 and end at 4.
- Then, when the variable X=1 then the condition of the outer loop become true and the check the condition of the inner loop, when Y=3, than the multiplication of X and Y occur and output should be 1*3=3.
- Then, the value of the X will remain same at time when the value of Y become false. Thrn, second time X=1 and Y=4 and output should be 4.
- Then, X=2 because Y turns 5 so the inner loop will terminate and than outer loop will execute. Then again Y=3 but X=2 and output should be 6.
- Then, the value of the X will remain same at time when the value of Y become false. Thrn, second time X=2 and Y=4 and output should be 8.
Finally, all the conditions of the loop become false and the program will terminate.