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
nadya68 [22]
2 years ago
12

Write a function solution that given an array a of n integers (between -100 and 100), returns the sign (-1,0,1) of product of al

l the numbers in the array multiplied
Computers and Technology
1 answer:
JulijaS [17]2 years ago
4 0

left[0]=a[0];

for(int i=1;i<=n-1;i++)

   left[i]=(left[i-1]*a[i])%M;

right[n-1]=a[n-1];

for(int i=n-2;i>=0;i--)

   right[i]=(right[i-1]*a[i])%M;

for query q

   if(q==0)

       return right[1]%M;

   if(q==n-1)

       return left[n-2]%M;

   return (left[q-1]*right[q+1])%M;

You might be interested in
Simplest way to start baking career is to attend_______.<br><br><br><br>​
ivolga24 [154]
...attend course
I hope my answer helps.
7 0
3 years ago
How to resize an image in photoshop without losing quality.
castortr0y [4]

Answer:

Explanation:

Make sure resample is turned on

Turn on the chain link if you want the width and height to change together. If not, turn off the chain so that you can set your own width and height.

Choose your new size (you can choose to choose different measurement units by clicking on “inches”)

press ok

i hoped this helped!!!!!!!!

8 0
2 years ago
Will somebody help me???? ANYBODY?? PLZZZZZZZZZZZZ
romanna [79]
I've never seen that third syntax. If it's legit, it probably does the same as I and II, which are the same.
6 0
3 years ago
What are the four steps of the research process?
pishuonlain [190]

Answer:

Step 1: Identify the Problem

Step 2: Review the Literature. ...

Step 3: Clarify the Problem Step 4: Clearly Define Terms and Concepts.

7 0
3 years ago
Distinguish between the desktop publishing packages and multimedia packages​
maksim [4K]

Answer:

___________________________________________________________

Word processing software is used for working with text, while desktop publishing software involves production of documents that combine text with graphics. DTP software is perfect for making flyers, brochures, booklets. This type of software is usually more advanced than word processing apps.

___________________________________________________________

4 0
2 years ago
Other questions:
  • 11. Describe an algorithm that interchanges the values of the variables x and y, using only assignments. What is the minimum num
    10·1 answer
  • Match each invention with its effects on the age of exploration.
    6·2 answers
  • Csc105 final graded project
    9·1 answer
  • Which of the following focuses on information related to disease identification, control, and prevention?
    10·1 answer
  • A list of sources used for in-text citations that appears at the end of a document is called:
    10·1 answer
  • What is theory of knowledge?​
    13·1 answer
  • Explain the major innavotions made from the establishment of abacus​
    8·1 answer
  • HELP PLS QUICK TRUE OR FALSE QUESTION
    7·2 answers
  • Porque es importante la tecnología?​
    8·1 answer
  • What is printed when the following code has been executed?
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!