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
vodomira [7]
3 years ago
8

Mypiecewise(a,b,c) which takes three inputs:

Computers and Technology
1 answer:
Step2247 [10]3 years ago
6 0

Answer:

function result = mypiecewise(a, b, c)

   if(c==0)

       result=5(a+b);

   elseif(c>0)

       result=(a*b=c);

   else

       result=-7;

   end

end

Explanation:

It is done in matlab.

You might be interested in
Please help, I can't find the answer but I understand the topic.
gladu [14]

Answer:

x=(2+3)*3;

Explanation:

3 0
3 years ago
Read 2 more answers
What is 4991 rounded to the nearest thousand
evablogger [386]

Answer:

5000

Explanation:

5 0
3 years ago
Read 2 more answers
Write a program that plays the popular scissor-rockpaper game. (A scissor can cut a paper, a rock can knock a scissor, and a pap
kolbaska11 [484]

Answer:

import random

computer = random.randint(0, 2)

user = int(input("scissor (0), rock (1), paper (2): "))

if computer == 0:

   if user == 0:

       print("The computer is scissor. You are scissor too. It is a draw")

   elif user == 1:

       print("The computer is scissor. You are rock. You won")

   elif user == 2:

       print("The computer is scissor. You are paper. Computer won")

elif computer == 1:

   if user == 0:

       print("The computer is rock. You are scissor. Computer won")

   elif user == 1:

       print("The computer is rock. You are rock too. It is a draw")

   elif user == 2:

       print("The computer is rock. You are paper. You won")

elif computer == 2:

   if user == 0:

       print("The computer is paper. You are scissor. You won")

   elif user == 1:

       print("The computer is paper. You are rock. Computer won")

   elif user == 2:

       print("The computer is paper. You are paper too. It is a draw")

Explanation:

*The code is in Python.

Import the random to be able to generate number number

Generate a random number between 0 and 2 (inclusive) using randint() method and set it to the computer variable

Ask the user to enter a number and set it to the user variable

Check the value of computer the computer variable:

If it is 0, check the value of user variable. If user is 0, it is a draw. If user is 1, user wins. If user is 2, computer wins

If it is 1, check the value of user variable. If user is 0, computer wins. If user is 1, it is a draw. If user is 2, user wins

If it is 2, check the value of user variable. If user is 0, user wins. If user is 1, computer wins. If user is 2, it is a draw

8 0
3 years ago
A communication sent through Transmission Control Protocol (TCP) arrives out of order. What allows the data to be put back toget
algol13

Answer:

Error detection.

Explanation:

Tcp is a transport layer protocol. It is said to be connection oriented because it requires a handshake or established connection between the sender and the receiver.

Once a handshake is made, the segments of the packets are sent across and the connection is closed.

The error detection does not only carry out integrity checks, but allows for sequence numbering from the sender to receiver. If the packets arrives out of order, the sequence numbers are used to arrange them in the correct order.

5 0
3 years ago
Please, give me a comic or story idea. I will mark brainliest. ( i need 5 slides with 2 characters in the story or comic) Please
salantis [7]

Answer:

Jack and John

Explanation:

Jack called John and offered him to come with him and some other friends to go out to the mall.

.....

8 0
3 years ago
Read 2 more answers
Other questions:
  • 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
    13·1 answer
  • Generally speaking, manufacturing overhead is applied to production by means of a __________ __________ __________, which is com
    11·2 answers
  • Yesterday you installed a new game on your computer. When you ran the computer, you noticed that the application was running ver
    15·1 answer
  • What is an example of a governmental influence ?
    9·2 answers
  • During which geologic era was nearly all of Earth's land concentrated into one giant mass called Pangaea?
    6·1 answer
  • Day 1 of seeing if anyone will buy me a psn gift card (if u do u get brainliest and thanks + alot of points
    11·1 answer
  • 13. Place where names, addresses and email information<br> is stored
    6·1 answer
  • please help no one is helping me on this one
    9·1 answer
  • Which of these skills are used in game design?
    8·1 answer
  • What three files do you need to perform a mail merge?<br><br> HELP ASAP PLEASE!!
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!