1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Juliette [100K]
3 years ago
9

What does the following code do? Assume list is an array of int values, temp is some previously initialized int value, and c is

an int initialized to 0. for (j=0; j < list.length; j++) if (list[j] < temp) c++;
Computers and Technology
1 answer:
erica [24]3 years ago
4 0

Answer:

It counts the number of items in the given list that are less than Description temp:

Explanation:

Following are the description of the loop  

  • In the given question initially, the value of "j" variable is initialized to 0.
  • After that loop will iterate less then the length of the list array.
  • The  if(list[j] < temp) checks the condition if it is true then c++ increment the value by 1  
  • j++ increment the value of "j" by 1.

You might be interested in
Write a repetition statement that outputs the numbers 45 , 51 , . . . , 165 . That is, all of the multiples of 6 in increasing o
Bingel [31]

Answer:

#include <iostream>

using namespace std;

int main()

{

   int i = 45;

   for ( i = 45; i <=165; i = i + 6)

       cout << i << endl;

}

Explanation:

I corrected your code and highlighted the mistakes. Even though you wrote the correct algorithm, your code did not compile because of the typos you made.

Remember, C++ is a case-sensitive language. That means, "For" is not same as "for".

Generally, variables and keywords are written in lower case. Of course, there are exceptions, such as constant variables are all written in uppercase letter and class names start with an uppercase letter.

8 0
3 years ago
​Which SQL keyword is used to search for records?
Over [174]
SQL (<span>Structured Query Language.) is the standard programming language for communicating and organizing databases (DB).
In order to search through the database the statement SELECT should be used.
SELECT select data from the database.
SELECT is followed by the statement FROM which defines from which database you search record. </span>
8 0
3 years ago
Look at the following structure declaration.
myrzilka [38]

Answer:

B. a tag

Explanation:

In the structure definition given below:

struct Employee

{

string name;

int idNum;  

};

Employee corresponds to the tag of the structure. The tag is used to create additional instances of the structure. For example:

struct Employee e1;

struct Employee e2;

name and idNum are members of the Employee structure and are referenced using the dot notation. e.g.,

struct Employee e1;

e1.idNum=1;

7 0
3 years ago
Ten output devices you know
jasenka [17]
Monitor
Printer
Headphones
Computer Speakers
Projector
GPS
Sound Card
Video Card
Braille Reader
Speech-Generating Device

6 0
3 years ago
Bill is pushing a box with 10 N of force to the left, while Alice is pushing the box with 30 N of force to the right. What is th
Greeley [361]

Answer:

Net force = 20 N

Explanation:

Given that,

Force acting on the left = 10 N

Force acting on the right = 30 N

Let right side is positive and left side is negative. Let the net force acting on the box is F. So,

F = -10+30

F = 20 N

So, the net force on the box is 20 N and it is in right side.

7 0
2 years ago
Other questions:
  • Can you help me correct a sentence?
    13·1 answer
  • What are the five resources paid for by local taxes
    15·1 answer
  • If an object moves without rotation or angular displacement, it is called translation.
    11·1 answer
  • Operating systems provide a measure of security by allowing users to access to those resources they've been cleared to use as we
    8·1 answer
  • Which of the following should you consider when
    5·1 answer
  • Write a program in C/C++ to draw the following points: (0.0,0.0), (20.0,0.0), (20.0,20.0), (0.0,20.0) and (10.0,25.0). For this
    6·1 answer
  • Writing a function that implements a loop to collect a set amount of data. The function should use the serial object, the record
    9·1 answer
  • Algorithm and flowchart to find the perimeter and area of square​
    15·1 answer
  • Yusuke has been a fan of online games for as long as she can remember. She particularly loves the role-playing games that allow
    7·1 answer
  • The second generation of computer languages is a higher-level language than
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!