Answer:
6=110
13=1101
18=10010
27=11011
Explanation:
A decimal number is converted to binary number by constantly dividing the decimal number by 2 till the number becomes zero and then write the remainders in reverse order of obtaining them.Then we will get our binary number.
I will provide you 1 example:-
18/2 = 9 the remainder =0
9/2 = 4 the remainder =1
4/2 = 2 the remainder =0
2/2 = 1 the remainder =0
1/2 = 0 the remainder =1
Writing the remainder in reverse order 10010 hence it is the binary equivalent of 18.
Answer:
print("Let's play Silly Sentences!")
print(" ")
name=input("Enter a name: ")
adj1=input("Enter an adjective: ")
adj2=input("Enter an adjective: ")
adv=input("Enter an adverb: ")
fd1=input("Enter a food: ")
fd2=input("Enter another food: ")
noun=input("Enter a noun: ")
place=input("Enter a place: ")
verb=input("Enter a verb: ")
print(" ")
print(name + " was planning a dream vacation to " + place + ".")
print(name + " was especially looking forward to trying the local \ncuisine, including " + adj1 + " " + fd1 + " and " + fd2 + ".")
print(" ")
print(name + " will have to practice the language " + adv + " to \nmake it easier to " + verb + " with people.")
print(" ")
print(name + " has a long list of sights to see, including the\n" + noun + " museum and the " + adj2 + " park.")
Explanation:
Got it right. Might be a longer version, but it worked for me.
Answer: True
Explanation:
Subset sum problem and Knapsack problem can be solved using dynamic programming.
In case of Knapsack problem there is a set of weights associative with objects and a set of profits associated with each object and a total capacity of knapsack let say C. With the help of dynamic programming we try to include object's weight such that total profit is maximized without fragmenting any weight of objects and without exceeding the capacity of knapsack, it is also called as 0/1 knapsack problem.
Similar to knapsack problem, in subset sum problem there is set of items and a set of weights associated with the items and a capacity let say C, task is to choose the subset of items such that total sum of weights associated with items of subset is maximized without exceeding the total capacity.
On the basis of above statements we can say that subset sum problem is generalization of knapsack problem.
Answer:
to count the number of cases that fall into different subgroups within a dataset.
Explanation:
To calculate the frequency within the dataset means to count the number of times that item or condition on which we are checking the column within the dataset is true or the frequency of the case that is coming into different subgroups.
Hence the answer of this question is third option given in the question.