answer.
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
inysia [295]
2 years ago
15

This exercise shows why each pivot (in eli1nination by pivoting) must be in a different row. (a) In Example 7, make the third pi

vot on entry (3, 3) instead of on entry (3, 2). Can you still read off the solution
Computers and Technology
1 answer:
Darya [45]2 years ago
8 0

Answer:gghggggggggggggg

Explanation:

You might be interested in
g 18.6 [Contest 6 - 07/10] Reverse an array Reversing an array is a common task. One approach copies to a second array in revers
Blababa [14]

Answer:

I am writing C++ program. Let me know if you want the program in some other programming language.  

#include <iostream> //to use input output functions

using namespace std; //to identify objects like cin cout

void reverse(int array[], int size){ //method to reverse an array  

int i, j, temp; //declare variables  

for (i = 0; i < size / 2; i++) { /* the loop swaps the first and last elements, then swap the second and second-to-last elements and so on until the middle of the array is reached */  

temp = array[i];  

array[i] = array[size - i - 1];  

array[size - i - 1] = temp; }  

cout<<"Reversed array: "; //prints the resultant reversed array after swapping process  

for (j = 0; j < size; j++) { //loop to print the reversed array elements  

cout<<array[j]<<" "; } }    

int main() { //start of main() function body  

cout<<"Enter the length of array: "; //prompts user to enter the length of the array

       int n; //stores the value of size of array

       cin>>n; //reads the input size of array

       int A[n]; //declare array A of size n

       cout<<"Enter the elements: "; //prompts user to enter array elements

       for(int i=0;i<n;i++){ //loop for reading the elements of array

           cin >> A[i];        }

         reverse(A,n); } //calls reverse function to reverse the elements of the input array A by passing array A and its length n to function reverse

Explanation:  

The reverse function takes an array and its length as parameter. In the body of reverse function three integer type variables i,j and temp are declared.

for (i = 0; i < size / 2; i++) The for loop has a variable to iterate through the array. The for loop checks if the value of i is less than the array length. Lets say we have an array of elements 1, 2, 3, 4. As i=0 and size/2 = 4/2= 2. So the condition checked in for loop is true as 0<2 which means the body of for loop will be executed.

In the body of the loop there are three swap statements.

temp = array[i] This statement stores the element of array at i-th index to temp variable.

array[i] = array[size - i - 1] statement stores the element of array at size-i-1 to array index i.  

array[size - i - 1] = temp statement stores the the value in temp variable to the array index size-i-1

In simple words first, the first and last elements of array are swapped, then the second and second last elements are swapped. This process keeps repeating and for loop keeps executing these swap statements until the middle of the array is reached. In this program no extra array is used for reversing procedure but just a variable temp is used to hold the array elements temporarily.

array[4] = { 1 , 2 , 3 , 4}  

At first iteration  

i < size/2 is true as 0<2  

So the program control moves in the body of the loop where three swap statement works as following:  

temp = array[i]  

temp = array[0]  

As element at 0-th index which is the first element of array is 1 so

temp= 1  

array[i] = array[size - i - 1];  

array[0] = array[4-0-1]  

           = array[3]  

As the element at 3rd index of array is 4 which is the last element of the array so

array[0] = 4

This means that 4 becomes the first element of array now.

array[size - i - 1] = temp  

As the value in temp was set to 1 so  

array[4-0-1] = 1  

array[3] = 1  

This means 1 is assigned to the 3rd index of array. Which means 1 becomes the last element of the array now.

This is how the first and last elements of array are swapped.  

2nd iteration: value of i is incremented to 1 and now i = 1  

Again for loop condition is checked which evaluates to true as 1<2

temp = array[i]  

temp = array[1]  

As element at 1st index which is the second element of array is 2 so

temp= 2  

array[i] = array[size - i - 1];  

array[1] = array[4-1-1]  

           = array[2]  

As the element at second index of array is 3 which is the last element of the array so

array[1] = 3  

This means that 3 becomes the second element of array now.

array[size - i - 1] = temp  

As the value in temp was set to 2 so  

array[4-1-1] = 2  

This means 2 is assigned to the 2nd index of array. Which means 2 becomes the second last element of the array now.

This is how the second and second to last elements of array are swapped.  

3rd iteration: value of i=2 The for loop body will not execute now as the for loop condition i<size-2 evaluates to false because 2=2. So the loop stops and next for (j = 0; j < size; j++) loop iterates through array[] which has now been reversed and print the elements of this reversed array.

Next the main() method passes length of the array and the array elements to the   reverse function and prints these elements in reverse.  

The output is:

4  3 2  1  

The program and output according to the example 2,5,9,7 given in the question is attached as a screenshot.

3 0
1 year ago
Q3** Write a query to create a new price list for books written by the same author. Allow the user to enter only the first 4 let
Harrizon [31]

Answer:

We will SQL(Structured Query Language) designed for this specific problem to manage the data base  for the library management system.This querry SQL based system will ask the user  to tell the first name and this SQL based system will his full name.

5 0
2 years ago
Write a method called printRangeOfNumbers that accepts a minimum, maximum numbers as parameters and prints each number from mini
timama [110]

Answer:

The method in python is as follows:

class myClass:

    def printRange(min,max):

         for i in range(min, max+1):

              print("{"+str(i)+"} ", end = '')

           

Explanation:

This line declares the class

class myClass:

This line defines the method

    def printRange(min,max):

This line iterates from min to max

         for i in range(min, max+1):

This line prints the output in its required format

              print("{"+str(i)+"} ", end = '')

5 0
2 years ago
Mike has never used a slide software before, but he needs to create a presentation by the end of the week. what recourse would b
ankoles [38]

This is an incomplete question. The complete question is given below:

Mike has never used slide presentation software before but he needs to create a presentation by the end of the week what resource would be most helpful to mike

a. The 350-page printed manual from the slide presentation software publisher

b. A free tutorial the slide presentation software publisher has posted on the company website

c. A trouble-shooting website created by a third party

d. The 350-page online manual from the slide presentation software publisher

Answer:

b - A free tutorial the slide presentation software publisher has posted on the company website

Explanation:

As Mike has a short time and no prior experience with a slide software, then in this scenario, the best, simplest and fastest way to learn and create a presentation a free tutorial which the slide presentation software publisher has posted on the company website  as this is the same company that has created this particular software so he can be rest-assured that the resource he is relying on is authentic and up-to-date with information on latest features.

Moreover, it's efficient and quick way to learn from a free tutorial rather than from 350-page printed or online manual especially for a beginner.

Besides, his purpose is to create the presentation using the software and not trouble-shooting so trouble-shooting website created by a third party is not useful for him and it also might not be authentic or updated as well.

6 0
1 year ago
Write a program to help you feed your friends at a party by doing some math about square pizzas. Assume the grader defines a str
Nina [5.8K]

Answer:

Following are the program in the Python Programming Language.

#get input from the user length of the pizza

inputStr = input('Enter the length of pizza: ')

#convert input into float

L = float(inputStr)

#initialize the area of the pizza

A = L*L

#calculate the amount of peoples can eat pizza

men = int(A/100)

#print the number of peoples

print('\nPizza can be eaten by {} people'.format(men))

<u>Output</u>:

Enter the length of pizza: 20

Pizza can be eaten by 4 people

Explanation:

<u>Following are the description of the program</u>.

  • Firstly, set a variable that get length input from the user.
  • Set variable 'L' that convert the input from the user into the float data type.
  • Set variable 'A' that stores the area of the pizza.
  • Set variable 'men' that store the amount of peoples can eat pizza.
  • Finally, print the number of peoples can eat pizza.
3 0
2 years ago
Other questions:
  • On the Picture Tools Layout tab, you can preview results of the numerous styles, borders, effects, and layouts by _______ comman
    7·2 answers
  • A company operates on two types of servers: 2 large servers (L) and 4 smaller servers (S), with a combined total of 64GB RAM. Th
    9·1 answer
  • Which of the following is NOT a method in which a macro can be run?
    10·1 answer
  • You are researching RAM for a computer you are building for a friend who will be using the system as a home office server for he
    14·1 answer
  • Big Data often involves a form of distributed storage and processing using Hadoop and MapReduce.
    12·1 answer
  • Database management systems are expected to handle binary relationships but not unary and ternary relationships.'
    7·1 answer
  • Some early computers protected the operating system by placing it in a memory partition that could not be modified by either the
    5·1 answer
  • Write a SELECT statement that selects all of the columns for the catalog view that returns information about foreign keys. How m
    6·1 answer
  • Suggest how the following requirements might be rewritten in a quantitative way. You may use any metrics you like to express the
    7·1 answer
  • For a data structure, such as a stack, who is responsible for throwing an exception if the stack is empty and a pop() is called:
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!