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
Kitty [74]
2 years ago
14

Difference between if then and if then else statement ​

Computers and Technology
1 answer:
Troyanec [42]2 years ago
6 0

Answer:

<em>if..then statement is used to make a decision when there is only two options. </em>

<em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em> </em><em>&</em>

<em>you have to write a program that have to choose from three options then we use if..then..else statement.</em>

<h3>I HOPE THIS WILL HELP YOU IF NOT THEN SORRY</h3>

HAVE A GREAT DAY :)

You might be interested in
Which of the following is a method which can be used to delete a page from a publication?
Alexandra [31]
Selecting the page and pressing the backspace key
3 0
3 years ago
let's imagine you're searching for hotels in searching chicago, what should you search for in order to get the most relevant res
n200080 [17]

Trivago, Trip advisor,

3 0
3 years ago
A software or hardware that checks information coming from the Internet and depending on the applied configuration settings eith
photoshop1234 [79]

Answer:

1. Firewall.

2. Router.

3. Proxy.

4. SMTP, 25.

Explanation:

1. A firewall is a network security protocol that monitors and controls inbound and outbound traffic based on set aside security rules.

Generally, a firewall is used to control access to a computer or network, as it creates a barrier between a computer or a network and the internet in order to protect against unauthorized access. It is a security system pre-installed on most computers to essentially inspect data being transmitted to or from a computer.

Furthermore, firewalls are typically bidirectional, it checks all sent and received data and only allow authorized traffic through.

2. A router can be defined as a network device that is designed typically for forwarding data packets between two or more networks based on a well-defined routing protocol.

A routing protocol refers to a set of defined rules or algorithms used by routers to determine the communication paths unto which data should be exchanged between the source router and destination or host device.

Additionally, in order for packets to be sent to a remote destination, these three parameters must be configured on a host.

I. Default gateway.

II. IP address.

III. Subnet mask.

3. A proxy can be defined as a computer network service designed to avail end users (clients) the ability to connect indirectly to other network services. For example, a reverse proxy is a type of server that is placed right in front of other servers such as a web server and it forwards or routes the user's (client) requests to those servers sitting behind it. When properly configured, reverse proxy helps to ensure security, reliability and performance of a network.

4. A spam filter can be defined as a software program designed to process all incoming electronic messages (e-mails) and prevents any unsolicited or unwanted mail (spam) from entering the inbox of a client.

Generally, a spam filter uses SMTP with port number 25 to carry out its services.

SMTP is an acronym for Simple Mail Transfer Protocol and it uses the standard port number of 25 to provide clients with requested services.

3 0
3 years ago
A cookie recipe calls for the following ingredients: • 1.5 cups of sugar • 1 cup of butter • 2.75 cups of flour The recipe produ
True [87]

The program that asks the user how many cookies they want to make and then displays the number of cups of each ingredient is corresponds to the ingredients mentioned above.

<h3>Further explanation</h3>

Python is a general-purpose programming language. We want to write a python program that asks the user how many cookies they want to make and then displays the number of cups of each ingredient.

48 cookies = 1.5 cups of sugar + 1 cup of butter + 2.75 cups of flour, so:

def main():

   cookies = float(input("How many cookies would you like to make?\n>"))

   sugar = (1.5 * cookies) / 48.0

   butter = cookies / 48

   flour = (2.75 * cookies) / 48

   print("To make ", cookies, " cookies, you will need:\n", \

         format(sugar, '.2f'), " cups of sugar\n", \

         format(butter, '.2f'), " cups of butter\n", \

         format(flour, '.2f'), " cups of flour", sep='')

   redoQuery()  

def redoQuery():

   yn = input("Would you like to check another batch size? (y/n)\n>")

   if yn == 'y':

       main()

   elif yn =='n':

       exit()

   else:

       print("Please enter only a lowercase \'y\' or lowercase \'n\'," \

             "then press enter")

       redoQuery()

main()

The run program is shown in the attachment below.

<h3>Learn more</h3>

1. Learn more about python https://brainly.in/question/8049240

 

<h3>Answer details</h3>

Grade:  9

Subject: Computers and Technology

Chapter:  programming with python

Keywords: python

4 0
3 years ago
Write a C program that will load entries from a file containing details of books and prints them.
Sladkaya [172]

Answer:

........

Explanation:

3 0
3 years ago
Other questions:
  • The domain in an email message tells you the
    5·1 answer
  • When Clara accesses the programs and documents on her computer by way of icons, she is said to be employing
    15·1 answer
  • The graph shows that sixty-eight percent of students think cyberbullying is a problem. One hundred human stick figures are shown
    14·2 answers
  • What do you do when your computer shuts down
    15·2 answers
  • Which line in the following program will cause a compiler error? 1 #include 2 using namespace std; 3 int main() 4 { 5 int number
    12·1 answer
  • How do you award a brainliest
    8·2 answers
  • Bakit mahalaga na marunong tayong gumamit ng makina?
    15·1 answer
  • 8.7 lesson practice question 1
    13·1 answer
  • How to make a message appear in more than one slack channel
    9·1 answer
  • PLEASE HELP. Nobody has been helping me, i need to resolve this code issue for game design
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!