viewRatings(string, int) Takes a username and a minimum rating value. It prints all the books that the user has rated with a value greater than or equal to the minimum rating value. The function does not return anything.

Answers

Answer 1
Answer:

Answer:

def ViewRatings(str, rating):

   for book in books:

       if r >= rating:

           print(book)

ViewRatings("emma", 3)

Explanation:

* The code is in Python.

Since the are missing parts in your question. I am assuming there is a books list and there is a rating, r for each book.

- Create a function called ViewRatings that takes two parameters

- Initialize a for loop that iterates through each book in the books list

- For each book, check its rating with given rating. If the rating of the book is greater than or equal to given rating, print the book

- Call the function


Related Questions

True / FalseIn the structure of a conventional processor, the computational engine is generally known as the arithmetic-logic unit.
Write a program that can be used to assign seats for a commercial airplane. The airplane has 13 rows, with six seats in each row. Rows 1 and 2 are first class, rows 3 through 7 are business class, and rows 8 through 13 are economy class. Your program must prompt the user to enter the following information: a. Ticket type (first class, business class, or economy class)b. Desired seatSo far the code I have is ... now can I go about finishing to retreive the user input ? (This is for C++)#include #include using namespace std;int main(){ int r, c; char seat_resvr; char tic_type; char availability[13][6], reserved[2]; int row_num, col_num; char seats; cout << "A program that lets you choose your seating arrangement on an airplane"; cout << endl; char A[13][6]; for (int r = 0; r < 13; r++) { for (int c = 0; c < 6; c++) A[r][c] = '*'; } /*int row, seat; cin >> row >> seat; A[row - 1][seat - 1] = 'X';*/ cout << " A B C D E F" << endl; for (int r = 0; r < 13; r++) { cout << "Row" << setw(3) << r + 1 << " "; for (int c = 0; c < 6; c++) cout << A[r][c] << ' '; cout << endl; } cout << endl << "* -- available seat" << endl << "X -- occupied seat" << endl << endl << "Rows 1 and 2 are for first class passengers." << endl << "Rows 3 through 7 are for business class passengers." << endl << "Rows 8 through 13 are for economy class passengers." << endl; cout << "To reserve a seat enter Y/y (Yes), N/n(No):" << endl; cin >> seat_resvr; reserved[2] = 'X'; return 0;}
How can we make our programs behave differently each time they are run?
A teacher at your school is using her district issued laptop to create spreadsheets for her part-time job as a bookkeeper. Which standard, if any, is this teacher violating?
Discuss thefactors that are vital to achieve clarity in themessage?

1. Do our shared social experiences lead us to think

communication is a cure-all?

Answers

Yes,  our shared social experiences lead us to think communication is a cure-all.

This is because, helps the individual in shaping their mental and emotional health for the rest of their life.

With shared social experiences , there would be communication among people and it serves as a cure-all.

Therefore, shared social experiences lead us to think communication is a cure-all.

Learn more about social experiences at:

brainly.com/question/24452126

Answer:

Yes

Explanation:

Shared social illustrations have always shown that any problem of any kind can be sorted by communication.

Eg : Whenever societies face any problem - eg recession, the competent people related to that area of problem (representing different interests of various groups also) sit & discuss (ie communicate in detail) about it.  

These communications have seen to be solution to all problems world has faced.

Jimmy Fallon's persona when he is outside the White House can best be characterized as:A. humble and excited.
B. outrageous and crazy.
C. stern and authoritative.
D. dark and serious.

Answers

B) outrageous and crazy
The answer to your question is b

In QlikView, ________ are used to search information anywhere in the document.

Answers

Answer:

Search Object

Explanation:

Qlikview is a form of computer software application that is basically used in analytics explanation. In order to search for information anywhere in the document inside the Qlikview application, a form of sheet object referred to as SEARCH OBJECT is utilized.

Hence, in this case, In QlikView, SEARCH OBJECT is used to search for information anywhere in the document.

How is a WAN different from a LAN

Answers

They make it easier for computers to connect to one another. WANs provide more options for communication than LAN networks, which are more constrained and limited in scope.

How are LANs and WANs different from one another?

A local area network, or LAN, is a network of computers created within a restricted area, like a home, business, or group of buildings. On the other hand, a wide-area network (WAN) is a computer network that spans a large geographic area. Users can transport data more quickly across LANs than they can via WANs, which have a significantly slower data transmission rate.

What distinguishes LAN and WLAN from one another?

LANs are straightforward networks that are used to link computers and other gadgets in a constrained space, such as a home, business, or campus. WLANs are entirely wireless in comparison to traditional LANs, which connect the devices using Ethernet cables. WLANs

To know more about LAN visit:-

brainly.com/question/13247301

#SPJ1

Implement the function calcWordFrequencies() that uses a single prompt to read a list of words (separated by spaces). Then, the function outputs those words and their frequencies to the console.Ex: If the prompt input is:

hey hi Mark hi mark
the console output is:

hey 1
hi 2
Mark 1
hi 2
mark 1

Answers

Answer:

JavaScript code is given below

Explanation:

function calcWordFrequencies() {

   var words = prompt("Enter the sentence below").split(" ");

   var unique_words = [], freqencies = [], count = 0;

   for (var i = 0; i < words.length; i++) {

       var found = false;

       for (var j = 0; j < count; j++) {

           if (words[i] === unique_words[j]) {

               freqencies[j] = freqencies[j] + 1;

               found = true;

           }

       }

       if (!found) {

           unique_words[count] = words[i];

           freqencies[count] = 1;

           count++;

       }

   }

   for (var i = 0; i < words.length; i++) {

       var result = 0;

       for (var j = 0; j < count; j++) {

           if (words[i] === unique_words[j]) {

               result = freqencies[j];

               break;

           }

       }

       console.log(words[i] + " " + result);

   }

}

Given the following code segment, what is output after "result = "? int x = 1, y = 2, z = 3; cout << "result = " << (x < y ? y : x) << endl;a. 1
b. 2
c. 3
d. 4

Answers

Answer:

b. 2

Explanation: