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
antiseptic1488 [7]
3 years ago
6

PLEASE HELP ITS CODING AND I INCLUDED A SCREENSHOT OF WHAT TO DO

Computers and Technology
2 answers:
elixir [45]3 years ago
7 0

num1 = float(input("Enter your first number: "))

num2 = float(input("Enter your second number: "))

operation = input("What operation would you like to do? Type: add, subtract, multiply, or divide. ")

def add(n, n1):

   return n + n1

def subtract(n, n1):

   return n - n1

def multiply(n, n1):

   return n*n1

def divide(n, n1):

   return n/n1

if operation.lower() in ["add", "+"]:

   result = add(num1, num2)

   print(num1,"+",num2,"=",result)

elif operation.lower() in ["subtract", "-"]:

   result = subtract(num1, num2)

   print(num1,"-",num2,"=",result)

elif operation.lower() in ["multiply", "*"]:

   result = multiply(num1, num2)

   print(num1, "*", num2, "=", result)

elif operation.lower() in ["divide", "/"]:

   result = divide(num1, num2)

   print(num1, "/", num2, "=", result)

else:

   print("Not a valid operation.")

I wrote my code in python 3.8. I hope this helps.

madam [21]3 years ago
6 0

Answer:

I need to have better photos in order to assist you...

Explanation:

I will attempt to get back with you if you can provide more clearer photos.

You might be interested in
How do you spell kiss in Japanese
atroni [7]

キッス (kissu) is the verb “to kiss” in Japanese
You can conjugated based on the sentence you are saying

5 0
3 years ago
Read 2 more answers
The parameter passing mechanisn used in C is
Step2247 [10]

Answer:

Hope you understand this answer

7 0
3 years ago
Read 2 more answers
P3. In Section 4.2 , we noted that the maximum queuing delay is (n–1)D if the switching fabric is n times faster than the input
Troyanec [42]

Answer:

All points are explained below in detail.

I hope it will help you

Explanation:

8 0
3 years ago
Provide the definition for each of the following structures and unions:
galben [10]

Answer:

a)

struct inventory  // structure inventory

{

char partName[ 30 ];  // char array

int partNumber;  // variable partNumber

float price;  // FLOAT VARIABLE PRICE

int stock ;  // INT VARIABLE STOCK

int reorder;  // INTEGER VARIABLE RECORDER

};

b)

union data // structure union

{

char c;  // char variable

short s; // short variable

long b; //

long variable float f ;  // float variable

double d ; // double variable

};

c)

struct address  // structure address

{

char streetAddress[ 25 ]; // character array

char city[ 20 ]; // variable char

char  state[ 3 ] ; // state array

char  zipCode[ 6 ] ; // zipcode array

};

d)

structure student  // structure student

{

char firstName[ 15 ]; // array first name

char  lastName[ 15 ] ;  // array last name

struct address * ;  // holding the home address

};

e)

struct test

{

unsigned a:1, b:1, c:1, d:1, e:1, f:1, g:1, h:1, i:1, j:1, k:1, l:1, m:1, n:1, o:1, p:1;

}; // prototype test assign value

Explanation:

Following are the description of the above part

a)

  • By using the struct keyword we declared the structure .In the part (a) we declared the struct  "inventory".In this structure we char array "partName " of size 30 .
  • We holding the 3 int variable "partNumber" , "stock" and "reorder." and 1 float variable i.e "price ".

b)

  • By using the union keyword we declared the union .In the part (b) we created the union .
  • Inside that union we holding different types of datatype that are mention in the question .

C)

  • By using the struct keyword we declared the structure  .In the part (c) we created the structure.
  • Inside that structure we holding array of character of variable "streetAddress","city","state" and "zipcode" by using char array .

d)

  • By using the struct keyword we declared the structure .
  • In this we declared array of "firstname" and "lastname" of char datatype .
  • In the last we create a structure address by using the pointer following by struct address

e)

In the part e we created the test that contain unsigned value of thhe 16 bit and 1 width

8 0
3 years ago
Hybrid processors that can process 32 bits or 64 bits are known by what term?
patriot [66]
For the answer to the question above asking, what h<span>ybrid processors that can process 32 bits or 64 bits are known by what term?

I think you are referring to the Chipset. and they are Manufactured by Intel and Advance Micro Devices (AMD). Intel's Pentium is the first one to have 32 bits and 64 bits of processors.</span>
4 0
3 years ago
Other questions:
  • What is html?
    9·2 answers
  • Diane wants to maintain a record of grades scored in the fifth, sixth, and seventh grades. She enters her grades and the total p
    13·1 answer
  • Which type of hypervisor does not run on an underlying operating system?
    13·1 answer
  • A marketing associate wants to use the Validate button to ensure an email is CAN-SPAM compliant. What information does the assoc
    5·2 answers
  • Match the item to the type.
    11·1 answer
  • Java public class Odds { public static void main(String[] args) { printOdds(3); printOdds(17/2); int x = 25; printOdds(37 – x +1
    12·1 answer
  • An EULA usually takes the form of an electronic notification that appears when installing software. The user then has a choice t
    14·1 answer
  • What does good time management mean​
    8·2 answers
  • Which is the correct expansion of the term Internet?
    15·2 answers
  • A small startup company has hired you to harden their new network. Because funds are limited, you have decided to implement a un
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!